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

Update and simplify error handling #571

Merged
merged 4 commits into from
Jan 22, 2025
Merged

Update and simplify error handling #571

merged 4 commits into from
Jan 22, 2025

Conversation

hugo-nl
Copy link
Collaborator

@hugo-nl hugo-nl commented Jan 22, 2025

πŸš‹ Centralized error middleware --> Removing GarboAPIError πŸ—‘οΈ
🌍 Adding fastify validation errors

Closes #562

Copy link
Collaborator

@Greenheart Greenheart left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We should define the schemas for HTTP 400 errors to make it explicit in the OpenAPI docs. This would make it easier to handle validation errors, and know what to expect when developing the frontend.

Copy link
Collaborator

@Greenheart Greenheart left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This turned out pretty nice! Ready to merge.

@hugo-nl hugo-nl merged commit e9de611 into staging Jan 22, 2025
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.

Expose validation errors to the client
2 participants