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

[Bug]: Vite errors on startup lead to confusing error #20242

Closed
tmeasday opened this issue Dec 14, 2022 · 3 comments
Closed

[Bug]: Vite errors on startup lead to confusing error #20242

tmeasday opened this issue Dec 14, 2022 · 3 comments

Comments

@tmeasday
Copy link
Member

tmeasday commented Dec 14, 2022

Describe the bug

A simple unmodified react-vite repro, erroring due to vite4:

yarn run v1.22.19
$ storybook dev -p 6006 --ci
@storybook/cli v7.0.0-beta.4

info => Starting manager..

attention => Storybook now collects completely anonymous telemetry regarding usage.
This information is used to shape Storybook's roadmap and prioritize features.
You can learn more, including how to opt-out if you'd not like to participate in this anonymous program, by visiting the following URL:
https://storybook.js.org/telemetry

WARN Force closed manager build
unable to close vite server
✔ Would you like to send crash reports to Storybook? … yes
TypeError: Cannot read properties of undefined (reading 'compilation')
    at Qn (/Users/tom/GitHub/tmeasday/space-before-import/node_modules/@storybook/cli/dist/generate.js:336:2531)
error Command failed with exit code 1.

To Reproduce

https://github.com/tmeasday/vite-startup-error

@IanVS
Copy link
Member

IanVS commented Dec 14, 2022

We're still working on vite 4 support, but 7.0.0-beta.6 does not crash upon startup, in your reproduction.

@tmeasday
Copy link
Member Author

Sure. This issue is really just about the error not being helpful rather than the crash itself @IanVS

@shilman
Copy link
Member

shilman commented Dec 14, 2022

Good golly!! I just released https://github.com/storybookjs/storybook/releases/tag/v7.0.0-beta.7 containing PR #20243 that references this issue. Upgrade today to the @next NPM tag to try it out!

npx sb upgrade --prerelease

Closing this issue. Please re-open if you think there's still more to do.

@shilman shilman closed this as completed Dec 14, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Archived in project
Development

No branches or pull requests

3 participants