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

Preserve field types when truncating large payloads #290

Merged
merged 2 commits into from
Apr 4, 2016

Conversation

duncanhewett
Copy link
Contributor

When truncating large payloads the event hash is passed into the reduce_hash_size' helper. This currently converts booleans and integers to strings which can result the payload being rejected by Bugsnag (particularly theinProject` field in a stackframe).

This will preserve integers and booleans in the truncated payload.

@kattrali kattrali force-pushed the fix-invalid-truncated-payloads branch 4 times, most recently from a9bbd18 to 9b12496 Compare April 4, 2016 20:51
* Handle array type cases
* Handle trimming and truncation
* Handle recursive Enumerables
* Add tests \o/
@kattrali kattrali force-pushed the fix-invalid-truncated-payloads branch from 9b12496 to 728bb36 Compare April 4, 2016 21:10
@kattrali
Copy link
Contributor

kattrali commented Apr 4, 2016

Added tests and handling for a few edge cases, such as floating-point values and arrays which contains objects other than hashes. Thanks, @duncanhewett!

@kattrali kattrali merged commit b61c48c into master Apr 4, 2016
@kattrali kattrali deleted the fix-invalid-truncated-payloads branch June 17, 2016 22:59
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