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

Nuxi generate: exits with success in case of an error #182

Closed
tobiasdiez opened this issue Nov 16, 2021 · 3 comments · Fixed by nuxt/framework#3134
Closed

Nuxi generate: exits with success in case of an error #182

tobiasdiez opened this issue Nov 16, 2021 · 3 comments · Fixed by nuxt/framework#3134
Assignees
Labels
bridge bug Something isn't working ❗ p4-important

Comments

@tobiasdiez
Copy link
Contributor

Environment

Reproduction

JabRef/JabRefOnline#480, and in particular the "build" step in https://github.com/JabRef/JabRefOnline/runs/4218058544?check_suite_focus=true

Describe the bug

If there is an error during the nitro server build (in my case #28), then nuxi generate just keeps going and returns the exit code 0 (success). Thus the CI workflow passes although it should fail in the presence of an error.

Additional context

No response

Logs

No response

@lihbr
Copy link
Member

lihbr commented Feb 7, 2022

@danielroe danielroe self-assigned this Feb 7, 2022
@danielroe danielroe added bug Something isn't working ❗ p4-important and removed pending triage labels Feb 7, 2022
@lihbr
Copy link
Member

lihbr commented Feb 8, 2022

repro-1968.zip

Find attached a minimal reproduction.

  1. Download and extract;
  2. Install dependencies;
  3. Run the dev script;

    You should see a "Hello Nuxt" page

  4. Run the generate script;

    You should seen thrown errors in the console but the script succeeding, actually generating HTML for "Internal Server Error"

  5. To fix the issue here you need to uncomment line 6 in nuxt.config.ts to transpile the dependency

    Actually this might be another issue, but it's quite off that it works fine in dev but breaks once generating for production, but well, ESM Hell 🔥

@tobiasdiez
Copy link
Contributor Author

Thanks @danielroe, this seems to work fine!

@pi0 pi0 transferred this issue from nuxt/framework Apr 13, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bridge bug Something isn't working ❗ p4-important
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants