Skip to content

Dependency: Fix Yarn 4 failing to install due to jscodeshift dependency issue#24914

Merged
valentinpalkovic merged 1 commit into
storybookjs:nextfrom
samvv:fix-jscodeshift-dep-error
Nov 20, 2023
Merged

Dependency: Fix Yarn 4 failing to install due to jscodeshift dependency issue#24914
valentinpalkovic merged 1 commit into
storybookjs:nextfrom
samvv:fix-jscodeshift-dep-error

Conversation

@samvv
Copy link
Copy Markdown
Contributor

@samvv samvv commented Nov 20, 2023

Closes #24913

What I did

When installing using yarn I get the following errors:

➤ YN0000: · Yarn 4.0.2
➤ YN0000: ┌ Resolution step
➤ YN0085: │ + @storybook/addon-essentials@portal:/home/samvv/Projects/storybook/code/addons/essentials::locator=before-storybook%40workspace%3A., and 697 more.
➤ YN0000: └ Completed in 7s 441ms
➤ YN0000: ┌ Fetch step
➤ YN0000: └ Completed
➤ YN0000: ┌ Link step
➤ YN0071: │ Cannot link @storybook/codemod into @storybook/cli@portal:/home/samvv/Projects/storybook/code/lib/cli::locator=before-storybook%40workspace%3A. dependency jscodeshift@npm:0.14.0 [251c9] conflicts with parent dependency jscodeshift@npm:0.15.1 [c0d42]
➤ YN0000: └ Completed
➤ YN0000: · Failed with errors in 8s 53ms

I changed code/lib/postinstall/package.json and code/lib/codemod/package.json that contained dependencies to jscodeshift and bumped their version numbers from 0.14.0 to 0.15.1. After that, I ran yarn, which generated a new yarn.lock. It did not seem to impact any other functionality.

Checklist for Contributors

Testing

The changes in this PR are covered in the following automated tests:

  • stories
  • unit tests
  • integration tests
  • end-to-end tests

Manual testing

I tried installing the dependencies using yarn. It now works as expected. Moreover, I ran yarn start in project root and checked that the example Storybook works.

yarn test in the project root gives errors but I'm sure the CI will catch those if they are non-local.

Documentation

  • Add or update documentation reflecting your changes
  • If you are deprecating/removing a feature, make sure to update
    MIGRATION.MD

Checklist for Maintainers

  • When this PR is ready for testing, make sure to add ci:normal, ci:merged or ci:daily GH label to it to run a specific set of sandboxes. The particular set of sandboxes can be found in code/lib/cli/src/sandbox-templates.ts

  • Make sure this PR contains one of the labels below:

    Available labels
    • bug: Internal changes that fixes incorrect behavior.
    • maintenance: User-facing maintenance tasks.
    • dependencies: Upgrading (sometimes downgrading) dependencies.
    • build: Internal-facing build tooling & test updates. Will not show up in release changelog.
    • cleanup: Minor cleanup style change. Will not show up in release changelog.
    • documentation: Documentation only changes. Will not show up in release changelog.
    • feature request: Introducing a new feature.
    • BREAKING CHANGE: Changes that break compatibility in some way with current major version.
    • other: Changes that don't fit in the above categories.

🦋 Canary release

This PR does not have a canary release associated. You can request a canary release of this pull request by mentioning the @storybookjs/core team here.

core team members can create a canary release here or locally with gh workflow run --repo storybookjs/storybook canary-release-pr.yml --field pr=<PR_NUMBER>

@valentinpalkovic valentinpalkovic changed the title Fix Yarn 4 failing to install due to jscodeshift dependency issue Dependency: Fix Yarn 4 failing to install due to jscodeshift dependency issue Nov 20, 2023
@valentinpalkovic valentinpalkovic self-assigned this Nov 20, 2023
@valentinpalkovic valentinpalkovic added dependencies ci:daily Run the CI jobs that normally run in the daily job. labels Nov 20, 2023
@valentinpalkovic
Copy link
Copy Markdown
Contributor

LGTM! Thank you :)

@valentinpalkovic valentinpalkovic merged commit b15a996 into storybookjs:next Nov 20, 2023
@github-actions github-actions Bot mentioned this pull request Nov 20, 2023
36 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ci:daily Run the CI jobs that normally run in the daily job. dependencies

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Bug]: Yarn 4.0.2 fails to link @storybook/codemod with @storybook/cli because jscodeshift has two different versions

2 participants