Trace
Requirement → acceptance criteria → tasks → commits → pull requests → reviews, with each criterion's AI verdict and its verification on the latest build.
REQ-CLICK-01: Terminal output respects user configuration REQ-CLICK-02: Styled output degrades gracefully REQ-CLICK-03: Breaking changes are announced one minor release ahead REQ-HTTPX-01: TLS configuration has one obvious way REQ-HTTPX-02: URLs are encoded the way browsers encode them REQ-HTTPX-03: Secrets never appear in logs REQ-REQ-01: Anything that behaves like a file is accepted REQ-REQ-02: Public type hints describe what callers may pass REQ-REQ-03: Security-relevant code works under FIPS SUB-CLI-01: Command-line output library (click) meets the baseline SUB-HTTP-01: HTTP client libraries (requests, httpx) meet the baseline SYS-01: Third-party client libraries meet the platform dependency baseline
REQ-REQ-02 · v3 changed 2026-06-20
Header inputs are typed as read-only Mapping: Requests never mutates a caller's headers. Response and Request attributes, including hooks, carry precise types with no Optional where the runtime never yields None.
3 versions
| v | Changed | Text | Why |
|---|---|---|---|
| 1 | 2026-05-08 | Header inputs accept mutable mappings so callers can pass dict or CaseInsensitiveDict. | initial |
| 2 | 2026-05-14 | Header inputs are typed as read-only Mapping: Requests never mutates a caller's headers. | Reversed after review of #7431. |
| 3 | 2026-06-20 | Header inputs are typed as read-only Mapping: Requests never mutates a caller's headers. Response and Request attributes, including hooks, carry precise types with no Optional where the runtime never yields None. | Extended to attributes after the 2.33 typing review. |
3 acceptance criteria
`Request.hooks` has a type annotation.
`Request.headers` is typed as a read-only `Mapping[str, str | bytes]`.
TASK-REQ-2021 done