Repository navigation
docs(transport): Fix stale comment referencing get_retry_after - #8333
Merged
Merged
Conversation
Contributor
Coverage Results 📊✅ 139303 passed | ⏭️ 7857 skipped | Total: 147160 | Pass Rate: 94.66% | Execution Time: 857m 53s 📊 Comparison with Base Branch
All tests are passing successfully. ✅ Patch coverage is 100.00% (no changed executable lines found; target 80%). Files with missing lines (1)
Coverage diff@@ Coverage Diff @@
## master #8333 +/-##
==========================================
+ Coverage 90.22% 90.25% +0.03%
==========================================
Files 203 203 —
Tracked lines 27333 27333 —
Branches 10242 10242 —
==========================================
+ Hits 24660 24667 +7
+ Misses 2673 2666 -7
Partials 1556 1556 —Generated by Coverage Action |
sentrivana
approved these changes
Nov 19, 2026
This was referenced Nov 19, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Description
This PR only changes a comment, in
sentry_sdk/transport.py(HttpTransportCore.__init__, line 226). No code changes.Old comment:
Why it's inaccurate: The transport no longer calls
get_retry_after. In 2bfce50d3 (#3588, the httpcore-basedHTTP2Transport), the 429 handling in_update_rate_limitswent fromself._retry.get_retry_after(response)to reading the header withself._get_header_value(response, "Retry-After")and passing the value toself._retry.parse_retry_after(retry_after_value). The httpcore response isn't a urllib3 response, soget_retry_after(response)can't be used anymore. That same commit added this comment, but the comment names the method the commit removed. Todayparse_retry_afteris the only method called onself._retry(sentry_sdk/transport.py,_update_rate_limits), andget_retry_afterappears nowhere insentry_sdk/.Fix: I kept the comment because it explains why the transport, which doesn't retry, creates a urllib3
Retryobject at all. I only changed the method name toparse_retry_after.Issues
n/a
via automation
sched_7b023adc5c6d74c9739cbbdca1ed3cf8· Run IDsched_7b023adc5c6d74c9739cbbdca1ed3cf8:1795075200000.--
View Session [Sentry]