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

Next.js don't show stack trace for unhandled rejection errors #31591

Closed
italodeandra opened this issue Nov 18, 2021 · 3 comments · Fixed by #36804
Closed

Next.js don't show stack trace for unhandled rejection errors #31591

italodeandra opened this issue Nov 18, 2021 · 3 comments · Fixed by #36804
Labels
bug Issue was opened via the bug report template.

Comments

@italodeandra
Copy link

What version of Next.js are you using?

12.0.1

What version of Node.js are you using?

16.13.0

What browser are you using?

Chrome

What operating system are you using?

Windows

How are you deploying your application?

next start

Describe the Bug

image

I can't debug or fix an error that I have no idea where it is.

Expected Behavior

It should show the complete stack trace for errors.

To Reproduce

Trigger an unhandled rejection errors.

@italodeandra italodeandra added the bug Issue was opened via the bug report template. label Nov 18, 2021
@paxmalipetek
Copy link

This started in v12. Check this example please.
https://stackblitz.com/edit/express-simple-vg8fq2?file=index.js

1- Load the example.
2- Click refresh on the frame.
3- See the error logged without stack.

@kodiakhq kodiakhq bot closed this as completed in #36804 May 11, 2022
kodiakhq bot pushed a commit that referenced this issue May 11, 2022
Stack trace disappears when error is converted to string.
I changed the types in `log.ts` to match `console.log`/`console.error`/`console.warn`.

fixes #31591
@ijjk
Copy link
Member

ijjk commented May 12, 2022

Hi, this has been updated in v12.1.7-canary.5 of Next.js, please update and give it a try!

@github-actions
Copy link
Contributor

This closed issue has been automatically locked because it had no new activity for a month. If you are running into a similar issue, please create a new issue with the steps to reproduce. Thank you.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Jun 12, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Issue was opened via the bug report template.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants