-
-
Notifications
You must be signed in to change notification settings - Fork 9.4k
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 Build hangs with addon-coverage + reactDocgen=react-docgen-typescript (+ ???) (reproduced in small project) #30424
Comments
** Disclaimer** This information might be inaccurate, due to it being generated automatically
|
Interesting, we are also having the hanging issue and disabling reactDocgen=react-docgen-typescript as you mentioned above also stops the process from hanging |
Ok so I found this while searching in the storybook codebase:
This never gets logged out even though we were using react-docgen-typescript with storybook v8? But doing typescript: {
reactDocgen: 'react-docgen'
//...
} We get the process running and exiting as expected. But that doesn't explain it on your reproduction repo, so I pulled that down and had a look through the node_modules and could see Running npm explain react-docgen-typescript
[email protected] dev
node_modules/react-docgen-typescript
react-docgen-typescript@"^2.2.2" from @joshwooding/[email protected]
node_modules/@joshwooding/vite-plugin-react-docgen-typescript
@joshwooding/vite-plugin-react-docgen-typescript@"0.4.2" from @storybook/[email protected]
node_modules/@storybook/react-vite
dev @storybook/react-vite@"^8.5.2" from the root project Looking at the if (reactDocgenOption === "react-docgen-typescript" && typescriptPresent && plugins.push(require("@joshwooding/vite-plugin-react-docgen-typescript")({
...reactDocgenTypescriptOptions,
savePropValueAsString: !0
})), typeof reactDocgenOption == "string") {
let {
reactDocgen: reactDocgen2
} = await Promise.resolve().then(() => (init_react_docgen(), react_docgen_exports));
plugins.unshift(await reactDocgen2({
include: reactDocgenOption === "react-docgen" ? /\.(mjs|tsx?|jsx?)$/ : /\.(mjs|jsx?)$/
}))
} Remove that block of code from the react-vite presets file and your reproduction builds correctly without hanging. So maybe the fix needs to happen in @storybook/react-vite with how this code block is checking for the existence of react-docgen-typescript? |
I think I've found the cause it seems the I did patch in the So the fix for this is @storybook/react-vite to upgrade @joshwooding/[email protected] In the meantime I just added an override to the reproduction repo to force v0.5.0 "overrides": {
"@joshwooding/vite-plugin-react-docgen-typescript": "0.5.0"
} |
Describe the bug
storybook build
is finishing but it hangs and never exits somehow.Keywords: halts, halting, stops, stuck
Reproduction link
https://github.com/LumaKernel/storybook-hang-issue
Reproduction steps
corepack npm ci
corepack npm run build:storybook
It hangs.
Screen.Recording.2025-01-30.at.19.11.41.mov
System
Additional context
Possibly related:
Confirmed:
npm create vite
'd project, it doesn't hang. That's why I'm writing + ??? in the title.Credits: The reproduction is made by minimizing the real work of Optimind.
The text was updated successfully, but these errors were encountered: