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]: Storybook fails to build on Vercel after update to v7 (React+Vite) #22409

Closed
abencun-symphony opened this issue May 5, 2023 · 8 comments

Comments

@abencun-symphony
Copy link

abencun-symphony commented May 5, 2023

Describe the bug

After migration from v6 to v7 we're seeing the following issue on Vercel:
image
Build works great anywhere except on Vercel. Seems like an issue with vite:dts plugin. Obviously, everything builds correctly, it's just the last step of the build where it fails to find a specific TS declaration file on the disk for some reason.

It's a fairly straightforward boilerplate setup with React and Vite as an UI library.

The project itself is contained within a PNPM monorepo and we're installing all monorepo dependencies prior to trying to build. Project folder itself is set as the project root. This configuration works great for a bunch of other projects we have and this seems to be working fine as well for this package as well - except for the last step.

I'd gladly report this to Vercel if this could actually be an issue on their end but I'm not sure it is as it seems like an issue with a file not being generated by the plugin properly or the file being accessed incorrectly.

To Reproduce

Try deploying a React+Vite Storybook project to Vercel.

System

The following environment info is IRRELEVANT as it's a Codespaces output, not Vercel builder output. However I'm posting it so package versions are visible.

Environment Info:

  System:
    OS: Linux 5.4 Ubuntu 22.04.1 LTS 22.04.1 LTS (Jammy Jellyfish)
    CPU: (8) x64 Intel(R) Xeon(R) Platinum 8370C CPU @ 2.80GHz
  Binaries:
    Node: 16.19.1 - /usr/bin/node
    npm: 8.19.3 - /usr/bin/npm
  npmPackages:
    @storybook/addon-actions: 7.0.8 => 7.0.8 
    @storybook/addon-essentials: 7.0.8 => 7.0.8 
    @storybook/addon-interactions: 7.0.8 => 7.0.8 
    @storybook/addon-links: 7.0.8 => 7.0.8 
    @storybook/react: 7.0.8 => 7.0.8 
    @storybook/react-vite: 7.0.8 => 7.0.8 
    @storybook/testing-library: 0.1.0 => 0.1.0

Additional context

No response

@IgnacioNMiranda
Copy link

IgnacioNMiranda commented May 7, 2023

Same here (: my config is public if anyone wants to take a look IgnacioNMiranda/vite-component-library-template#61

@shilman
Copy link
Member

shilman commented May 8, 2023

Possibly related @ndelangen ? #22261

@yanir-armis
Copy link

It also happened for me in GitHub action after updating the storybook version from 6 to 7

@ndelangen
Copy link
Member

@abencun-symphony could you try storybook version v7.1.0-alpha.12, see if this still occurs then?

@abencun-symphony
Copy link
Author

abencun-symphony commented May 17, 2023 via email

@ndelangen
Copy link
Member

I actually suspect the PR mentioned above might have fixed it. Great to hear it's been resolved!

@IgnacioNMiranda
Copy link

@ndelangen I tried with both 7.0.12 and v7.1.0-alpha.12 and is still not working :/
image
You can see the versions I'm using here https://github.com/IgnacioNMiranda/vite-component-library-template/blob/chore/update-deps/package.json

@jamilalisgandarov
Copy link

Still having an issue with version 8.1

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

6 participants