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

26 error handling #39

Merged
merged 20 commits into from
Jul 8, 2024
Merged

26 error handling #39

merged 20 commits into from
Jul 8, 2024

Conversation

mikeheft
Copy link
Owner

@mikeheft mikeheft commented Jul 8, 2024

Adds middleware to catch all errors. This allows us to have a more consistent error shape for all error and reduces the need for special handing in each controller.

  • New middleware in app/middleware/error_handling
  • Dynamically creates custom error classes to map internal errors like PG errors and ActiveRecord errors into out shape. This ensures the shape for all errors is able to be mapped consistently for future development ease.

@mikeheft mikeheft linked an issue Jul 8, 2024 that may be closed by this pull request
@mikeheft mikeheft merged commit 7822f98 into main Jul 8, 2024
2 checks passed
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

Successfully merging this pull request may close these issues.

Error Handling
1 participant