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

[v2] yarn build hangs forever after build is completed successfully #2431

Closed
avkonst opened this issue Mar 20, 2020 · 4 comments
Closed

[v2] yarn build hangs forever after build is completed successfully #2431

avkonst opened this issue Mar 20, 2020 · 4 comments
Labels
bug An error in the Docusaurus core causing instability or issues with its execution

Comments

@avkonst
Copy link

avkonst commented Mar 20, 2020

🐛 Bug Report

Docs for my project can not be built non-interactively as 'yarn-build' hangs forever.

Have you read the [Contributing Guidelines on issues]

yes

To Reproduce

git clone https://github.com/avkonst/hookstate
cd hookstate/hookstate.js.org/docs2
yarn build

Expected behavior

Build is finished and process exists

Actual Behavior

Build is successful (according to logs), but the process does not exit.

Your Environment

  • Docusaurus version used: 2 alpha 48
  • Operating system and version (desktop or mobile): see it on linux (netlify automated build) and windows (my working desktop)

Reproducible Demo

See above how to reproduce

@avkonst avkonst added bug An error in the Docusaurus core causing instability or issues with its execution status: needs triage This issue has not been triaged by maintainers labels Mar 20, 2020
@tomByrer
Copy link

tomByrer commented Mar 22, 2020

I got the same hung issue, even though on the same system running the basic template (npx @docusaurus/init@next init my-website classic) ran fine.

Perhaps something with your config? I do not get the following errors installing the template: that I got installing your site:

git clone https://github.com/avkonst/hookstate
cd hookstate/hookstate.js.org/docs2
yarn build
yarn install v1.22.1
[1/4] Resolving packages...
[2/4] Fetching packages...
info [email protected]: The platform "win32" is incompatible with this module.
info "[email protected]" is an optional dependency and failed compatibility check. Excluding it 
from installation.
info [email protected]: The platform "win32" is incompatible with this module.
info "[email protected]" is an optional dependency and failed compatibility check. Excluding it
 from installation.
[3/4] Linking dependencies...
warning " > @babel/[email protected]" has unmet peer dependency "@babel/core@^7.0.0-0".
warning " > @docusaurus/[email protected]" has incorrect peer dependency "@docusa
urus/core@^2.0.0".
warning "@docusaurus/preset-classic > @docusaurus/[email protected]" has inc
orrect peer dependency "@docusaurus/core@^2.0.0".
warning "@docusaurus/preset-classic > @docusaurus/[email protected]" has inc
orrect peer dependency "@docusaurus/core@^2.0.0".
warning "@docusaurus/preset-classic > @docusaurus/[email protected]" has in
correct peer dependency "@docusaurus/core@^2.0.0".
warning "@docusaurus/preset-classic > @docusaurus/[email protected]" has
 incorrect peer dependency "@docusaurus/core@^2.0.0".
warning "@docusaurus/preset-classic > @docusaurus/[email protected]" has inco
rrect peer dependency "@docusaurus/core@^2.0.0".
warning "@docusaurus/preset-classic > @docusaurus/[email protected]" has incorrec
t peer dependency "@docusaurus/core@^2.0.0".
warning "@docusaurus/preset-classic > @docusaurus/[email protected]" has incorrec
t peer de peer dependency "@docusaurus/core@^2.0.0".
pendency "@docusaurus/core@^2.0.0".
warning "@docusaurus/preset-classic > @docusaurus/[email protected]" has incorrec
t peer depwarning "@docusaurus/preset-classic > @docusaurus/[email protected]" has in
                                                                                                                            wwarning "@docusaurus/preset-classic > @docusaurus/[email protected]" has incorrect peer dependency "@docusaset-classic > @docusaurus/[email protected]" has unmet peer dependency "webp  ack@^4.41.2".                    aur dependency "@docusaurus/core@^2.0.0".
warning "@docusaurus/preset-classic > @docusaurus/theme-classic > [email protected]" has unmet peer dependency "prop-types@^15.3.0 
|| ^16.0.0".
[4/4] Building fresh packages...
success Saved lockfile.
Done in 30.49s.

@lex111
Copy link
Contributor

lex111 commented Mar 23, 2020

Resolved in #2443.

@lex111 lex111 closed this as completed Mar 23, 2020
@lex111 lex111 added this to the v2.0.0-alpha.49 milestone Mar 23, 2020
@jmlopez-rod
Copy link

I think this bug is back in 3.6.0, the build is successful but the process never exits. Not sure if it's worth opening another issue given that this is the exact issue I'm experiencing right now.

@slorber
Copy link
Collaborator

slorber commented Nov 7, 2024

@jmlopez-rod yes it's mentioned in the release notes:

We removed a process.exit(0) that can hide memory leaks in your own code and third-party plugins

Adding this code was a bad idea that hides problems on your own site. You should figure out the problem on your site and the build will terminate.

At best, I'd be ok to add a CLI option --force-terminate, or a secret env variable. But it has to be opt-in, and not the default, because we really want you to be aware and fix the leaks you have on your site.

Please join the conversation at #10410, I can help troubleshoot it if you provide a repro.

@slorber slorber removed the status: needs triage This issue has not been triaged by maintainers label Nov 7, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug An error in the Docusaurus core causing instability or issues with its execution
Projects
None yet
Development

No branches or pull requests

5 participants