Max_trace_back = 0 returns full exception stack trace bug fix. (#120) #123
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Check on max_trace_back in the recorder configuration now checks type as well as value >= 0
instead of pythonic variable check.
Furthermore, fixed an issue where if an empty list was used as the argument in the Throwable type initialization that it would cause the segment serialization to fail and therefore not send the segment to the daemon at all. This was causing issues when a segment was capturing a method while the max_trace_back configuration was set to 0 since it would pass in an empty list to the Throwable type initialization.
Added unit test to ensure zero value contains no stack. Tested on my local flask application as well to ensure no other issues would occur.
Issue #, if available:
#120
Description of changes:
Explicit int type checking for recorder.configuration of variable max_stack_trace, and ensuring that the value passed in is >= 0.
Testing:
By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.