Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Core: Fix packageName check in build-dev #16823

Merged
merged 1 commit into from Nov 29, 2021
Merged

Core: Fix packageName check in build-dev #16823

merged 1 commit into from Nov 29, 2021

Conversation

ThaNarie
Copy link
Contributor

The current check breaks for non-storybook packages.

Array.split always returns 1 items at minimum, so with a > 0 check in there it always executed the "if" part, breaking on the .split()[1] after.

What I did

Change to a > 1 check to allow accessing the 2nd item in the Array.

How to test

I guess there is no non-storybook packaged framework included in the kitchen sink or other tests, otherwise this would have failed already.

At minimum, all existing test should still pass with this change.

The current check breaks for non-storybook packages.

`Array.split` always returns 1 items at minimum, so with a `> 0` check in there it always executed the "if" part, breaking on the `.split()[1]` after.
@nx-cloud
Copy link

nx-cloud bot commented Nov 29, 2021

Nx Cloud Report

CI ran the following commands for commit bfb942b. Click to see the status, the terminal output, and the build insights.

📂 See all runs for this branch

Status Command
#000000 nx run-many --target=prepare --all --parallel --max-parallel=15

Sent with 💌 from NxCloud.

@shilman shilman added maintenance User-facing maintenance tasks bug core and removed maintenance User-facing maintenance tasks labels Nov 29, 2021
Copy link
Member

@shilman shilman left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good catch @ThaNarie ! Thank you! 🤦

@shilman shilman added the cli label Nov 29, 2021
@shilman shilman changed the title Fix packageName check in build-dev Core: Fix packageName check in build-dev Nov 29, 2021
@shilman shilman merged commit 72735c6 into storybookjs:next Nov 29, 2021
@tarinrickett
Copy link

@shilman – I just ran into this issue when updating versions in @glimmerx/storybook. When can we expect this fix to be published?

@shilman
Copy link
Member

shilman commented Nov 29, 2021

@tarinrickett will publish today

@shilman shilman added patch:yes Bugfix & documentation PR that need to be picked to main branch patch:done Patch/release PRs already cherry-picked to main/release branch labels Nov 30, 2021
shilman added a commit that referenced this pull request Nov 30, 2021
Core: Fix packageName check in build-dev
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug cli core patch:done Patch/release PRs already cherry-picked to main/release branch patch:yes Bugfix & documentation PR that need to be picked to main branch
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants