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

Don't disable stack traces #776

Closed
Frando opened this issue Jan 22, 2021 · 2 comments
Closed

Don't disable stack traces #776

Frando opened this issue Jan 22, 2021 · 2 comments
Labels

Comments

@Frando
Copy link

Frando commented Jan 22, 2021

Issue type:

  • 🐛 Bug

Description:

comunica disables all stack traces when process.env.NODE_ENV === 'production'. This is not something a library should do. As Error.stackTraceLimit is a superglobal affeting the whole context (browser page or node.js process), the decision of whether you want stack traces or not should be up to the application, not a library.

Enviornment:

Node.js v14, using comunica through node-quadstore v7.

Quadstore intensifies the situation because it ships a bundled version of itself through npm, with the bundler configured to replace process.env.NODE_ENV === 'production' with true. However, even without that, I wouldn't want my stack traces to always go away if I have NODE_ENV set to production for other reasons.

@github-actions
Copy link

Thanks for reporting!

@rubensworks
Copy link
Member

You're right. This is a leftover "hack" from back in the day that should not be here anymore.
I should probably redo the performance evaluations, as I suspect the stacktrace limits won't have a significant impact on performance anymore.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
Archived in project
Development

No branches or pull requests

2 participants