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

Structured stack trace access #235

Open
nitsky opened this issue Feb 9, 2024 · 2 comments
Open

Structured stack trace access #235

nitsky opened this issue Feb 9, 2024 · 2 comments

Comments

@nitsky
Copy link

nitsky commented Feb 9, 2024

Hi, I would like to be able to access an exception's stack trace as structured data, so that I can apply source maps and serialize it to my own representation. Right now, QuickJS only exposes the stack trace as a string. With V8, I can do this with Error.prepareStackTrace. See here: https://v8.dev/docs/stack-trace-api. Thank you!

@saghul
Copy link
Contributor

saghul commented Feb 9, 2024

FWIW I implemented that like so: quickjs-ng/quickjs@555d837

@chqrlie
Copy link
Collaborator

chqrlie commented Feb 11, 2024

I am going to merge @saghul code into quickjs, but I need some time to commit some other stuff before.

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

No branches or pull requests

3 participants