-
Notifications
You must be signed in to change notification settings - Fork 569
feat: Remove string truncation for events #5095
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
base: major/3.0
Are you sure you want to change the base?
Conversation
❌ 1 Tests Failed:
View the top 1 failed test(s) by shortest run time
To view more test analytics, go to the Test Analytics Dashboard |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Bug: Truncation Limit Ignored for Local Variables
The serialize() call for local variables doesn't pass through the max_value_length parameter from serialize_frame(), causing local variables to never be truncated even when users explicitly set max_value_length. This breaks the intended truncation behavior for stack frame local variables.
sentry_sdk/utils.py#L620-L624
sentry-python/sentry_sdk/utils.py
Lines 620 to 624 in 6238237
| def current_stacktrace( | |
| include_local_variables=True, # type: bool | |
| include_source_context=True, # type: bool |
Description
Remove the default string limit applied when serializing envelopes.
The
max_value_lengthparameter is now optionallyNone, in which case there is no string truncation. The default value is changed toNone.The change follows on from raising the limit in #4632.
Replaces
DEFAULT_MAX_VALUE_LENGTHwith the 1024 literal in tests, which was the original limit.Issues
Closes #4988
Closes PY-1916
Reminders
tox -e linters.feat:,fix:,ref:,meta:)