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

Check for a better way to handle errors #98

Open
heliomar-pena opened this issue Sep 15, 2022 · 2 comments
Open

Check for a better way to handle errors #98

heliomar-pena opened this issue Sep 15, 2022 · 2 comments
Labels
question Further information is requested

Comments

@heliomar-pena
Copy link
Contributor

heliomar-pena commented Sep 15, 2022

Currently, there are close to 1000 errors in the database
imagen

I checked and these errors don't look so much helpful
imagen

Also, Heroku has a limit of 10.000 rows of free
imagen

So we should try to think of a way to save useful errors to debug, saving rows on Heroku, and having always useful logs to check when a user in production has some error. Also, we want that the solution was not exhaustive how to write manually the line of code of the error.

@heliomar-pena
Copy link
Contributor Author

heliomar-pena commented Sep 15, 2022

I think that something interesting to save is the stack_trace, if we create a new Error in the catch statement, for example:
imagen

We could see at the stack trace the function name and the line of code:
imagen

But in production, as the code is formatted by webpack to save space and browser compatibility, the stack trace is not showing the line of code exact, and the name of the file and function is hidden between a lot of text.
imagen

I would like to have a more clean stack trace

@heliomar-pena
Copy link
Contributor Author

I don't found any way to get a more clean Stack trace in Javascript.

The only thing that I found is the Custom Errors that could help a little but not all ;( Here's the best article that I found about custom errors and error handling: https://javascript.info/custom-errors . But that won't cover complete our requirements.

@heliomar-pena heliomar-pena added the question Further information is requested label Sep 15, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested
Projects
None yet
Development

No branches or pull requests

1 participant