astarte-platform / astarte

Core Astarte Repository
https://docs.astarte-platform.org/
Apache License 2.0
238 stars 46 forks source link

{Pairing, Housekeeping, RM} API: Handle `Bad Request`s #894

Closed Annopaolo closed 7 months ago

Annopaolo commented 7 months ago

Do not return an error 400 with message "Internal server error" if a request has an unparsable payload (e.g. a badly written CSR). Return the more semantically correct "Bad request" message instead.

codecov[bot] commented 7 months ago

Codecov Report

Attention: 3 lines in your changes are missing coverage. Please review.

Comparison is base (210eca0) 68.72% compared to head (cd3f480) 68.68%.

Files Patch % Lines
...b/astarte_housekeeping_api_web/views/error_view.ex 0.00% 1 Missing :warning:
...pi/lib/astarte_pairing_api_web/views/error_view.ex 0.00% 1 Missing :warning:
...tarte_realm_management_api_web/views/error_view.ex 0.00% 1 Missing :warning:
Additional details and impacted files ```diff @@ Coverage Diff @@ ## release-1.0 #894 +/- ## =============================================== - Coverage 68.72% 68.68% -0.04% =============================================== Files 247 247 Lines 5550 5553 +3 =============================================== Hits 3814 3814 - Misses 1736 1739 +3 ```

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.