fix: close trace HTTP test response and listener resources - #1152
Conversation
|
Warning Review limit reachedNext included review available in 16 minutes. View limit detailsLimit details: You’ve used the included review currently available. You've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository. Review configuration: ⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Advanced Run ID: 📒 Files selected for processing (5)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
|
Restacked on the updated base branch ( 🤖 Addressed by Claude Code |
a675e7a to
4d2f47e
Compare
Main introduced test_split_token_mode without server_close; apply the PR's listener ownership pattern so strict ResourceWarning checks stay green. Co-authored-by: Cursor <cursoragent@cursor.com>
4d2f47e to
3a821bf
Compare
Scope and ownership
Stacked on #1140 at 38c0603. This preserves its production response-lifecycle delta and adds only trace HTTP test-resource ownership plus documentation. Production authentication, routing, retries, and response bodies are unchanged.
The test client's urllib HTTPError is separate from the server's serialized authorization failure. Both test request helpers now close that response after decoding while preserving primary decoding errors if cleanup raises OSError. All 23 test listener teardown paths close their sockets after shutdown/join. No warning suppression or global cleanup is introduced.
Evidence
Visual inspection and limits
At b9ad721, the changed runbook, Gap baseline, AGENTS and CLAUDE sections were rendered in a real browser at 1265 x 712, English, and screenshots directly inspected. New paragraphs and the complete evidence table were readable without overlap or horizontal clipping. This is a bounded documentation inspection, not full product UI, responsive, or multilingual acceptance.
Exact-head commands, logs and limitations are in docs/doctoring/http_test_resource_lifecycle.md. Cleanup injection covers OSError after underlying close, not arbitrary exception classes or a close that cannot complete. No measured customer accuracy or decision-latency improvement is claimed. Remains Draft pending full strict remediation, required hosted checks and independent review; no merge or deployment is requested.