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

Enhance Error Handling Middleware to Provide Clearer Error Messages (Later) #701

Open
ydahal1 opened this issue Feb 29, 2024 · 0 comments
Open

Comments

@ydahal1
Copy link
Collaborator

ydahal1 commented Feb 29, 2024

We need to implement a middleware function that handles error messages appropriately in our application. Currently, when an error occurs, the error object is passed to the logger function, which logs it but doesn't consider the origin of the error. For instance, the error messages logged do not clearly indicate errors generated by MySQL, such as constraint violations.

Expected Behavior:

The middleware function should intercept errors and provide detailed logging that identifies the origin of the error, especially in cases where MySQL constraints are violated.
Error messages logged should clearly indicate the source of the error, making it easier for developers to identify and address the root cause.

@BaharF BaharF changed the title Enhance Error Handling Middleware to Provide Clearer Error Messages Enhance Error Handling Middleware to Provide Clearer Error Messages (Later) Mar 25, 2024
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

1 participant