-
-
Notifications
You must be signed in to change notification settings - Fork 3.4k
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
Replaced all console.error with p5._friendlyError #6674
Conversation
🎉 Thanks for opening this pull request! Please check out our contributing guidelines if you haven't already. And be sure to add yourself to the list of contributors on the readme page! |
Since this is my first contribution i didnt exactly understand what is inline documentation and unit tests. Please accept the pull request as i have put a lot of time in this contribution |
@all-contributors please add @samrudh3125 for THING(S) |
I couldn't determine any contributions to add, did you specify any contributions? |
all-contributors please add @your-username for p5.js |
@all-contributors please add @samrudh3125 for processing/p5.js |
I couldn't determine any contributions to add, did you specify any contributions? |
@all-contributors please add @samrudh3125 for a11y |
I've put up a pull request to add @samrudh3125! 🎉 |
Hey @samrudh3125, thanks a lot for your work on this. However, that's not exactly how it works. For example, when I use console.err(e), it means I’m unsure of what’s happening or what kind of error might be occurring, and we get a line from the p5.js library. Friendly errors, on the other hand, are designed to be more helpful to the user. They point out the specific line in your code where the issue happened and even suggest possible solutions. These errors are not only formatted clearly but also provide guidance. You can see an example below where both an error message and a friendly error message are shown. So, closing this PR, but thanks a lot on your work. |
Resolves #6630
Changes:
All the console.error in the codebase were replaced with p5._friendlyError. Since this is my first contribution kindly accept this.Screenshots of the change:
PR Checklist
npm run lint
passes