Skip to content

Conversation

@moodix
Copy link
Contributor

@moodix moodix commented Apr 1, 2025

Previously, when encountering malformed JSON in request bodies, the json() method would raise a JSONDecodeError. This change updates the method to catch the exception and return None instead, providing more consistent behavior and preventing unexpected crashes.

Added a test case to verify this error handling behavior.

Previously, when encountering malformed JSON in request bodies, the json() method would
raise a JSONDecodeError. This change updates the method to catch the exception and
return None instead, providing more consistent behavior and preventing unexpected
crashes.

Added a test case to verify this error handling behavior.
@moodix moodix marked this pull request as ready for review April 1, 2025 16:52
@moodix moodix requested a review from a team as a code owner April 1, 2025 16:52
Copy link
Contributor

@sentrivana sentrivana left a comment

Choose a reason for hiding this comment

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

Thanks @moodix!

@moodix
Copy link
Contributor Author

moodix commented Apr 3, 2025

@sentrivana Looks like the workflow might need approval

@sentrivana sentrivana enabled auto-merge (squash) April 3, 2025 14:42
@sentrivana sentrivana merged commit 2b3b82d into getsentry:master Apr 3, 2025
138 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.

2 participants