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

Error message: Failed to collect Storybook metadata #324

Closed
domyen opened this issue Apr 22, 2021 · 5 comments
Closed

Error message: Failed to collect Storybook metadata #324

domyen opened this issue Apr 22, 2021 · 5 comments
Labels
customer reported Tracking: This issue was reported through customer support enhancement Classification: New feature or request tiny Estimate: <= 2 hours

Comments

@domyen
Copy link
Member

domyen commented Apr 22, 2021

Error: ✖ Failed to collect Storybook metadata
Could not find a supported Storybook viewlayer package. Make sure one is installed, or set CHROMATIC_STORYBOOK_VERSION.
at...

Users often get this message because Storybook is not installed as a dependency in their environment. This can happen in CI or locally if they've just cloned the project.

Strawman
Be more direct about a possible solution.

Error: ✖ Failed to collect Storybook metadata
Could not find a supported Storybook view layer package. This can happen if the dependency hasn't been installed in your environment yet. Run `npm install` or `yarn` to make sure Storybook is installed. 

If Storybook is installed, you can also set CHROMATIC_STORYBOOK_VERSION.
at...

┆Issue is synchronized with this Asana task by Unito

@tmeasday tmeasday added customer reported Tracking: This issue was reported through customer support enhancement Classification: New feature or request labels Apr 23, 2021
@domyen
Copy link
Member Author

domyen commented Apr 23, 2021

This is resolved by PR #319 and related to #317. Close when those are merged.

@BeeeQueue
Copy link

We have an internal package that installs all relevant storybook packages as dependencies and contains configuration and utilities.

root
  node_modules
    storybook-config
      node_modules
        chromatic
        storybook

We're getting the error telling us storybook isn't installed since it's in a nested folder.

Does this solution handle this?

@productdevbook
Copy link

some problem

@jackmccloy
Copy link

@domyen just wanted to give you a heads up that is also seems to happen if you use yarn v1 workspaces and install packages at the workspace root, rather than in individual projects (which isn't exactly a great practice, but can be convenient for projects that use create-react-app).

the workaround is to list your current version of storybook as a dependency or devdependency in the project itself, but it'd be lovely if it worked w/o having to do this (as it did a month or so ago)

@tmeasday
Copy link
Member

Released 5.8.1 which reverts to something similar to the earlier behaviour, please try it out.

@tmeasday tmeasday removed this from the Q2 Improvements milestone Jun 30, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
customer reported Tracking: This issue was reported through customer support enhancement Classification: New feature or request tiny Estimate: <= 2 hours
Projects
None yet
Development

No branches or pull requests

5 participants