Update README.md#4
Merged
Merged
Conversation
sbneto
added a commit
that referenced
this pull request
May 27, 2026
…p + respx coverage
Bot review found one code cleanup and several spec drift / coverage gaps.
Code:
- refresh_engine_cache now uses resources.Engine.list(self) instead of
building the descriptor inline. Engine._list_headers already returns
{'Authorization': None}, so the builder produces the same wire shape.
Brings the method in line with AGENTS.md §"When adding a new resource"
and specs/02-resources.md.
- Canonical docstrings in aio/session.py rephrased to be transport-
neutral ("AsyncClient on the async transport; Client on the sync
transport"). Reads correctly from both the canonical and generated
files.
Specs:
- specs/01-architecture.md: dropped the "PR #298" reference (this PR;
rots after merge). Added a note linking HttpxResponseAdapter to the
streaming-downloads follow-up in 99-open-questions.
- specs/04-testing.md: added an explicit note that _AsyncToSync is
respx-only — the harness builds the AsyncClient outside any event
loop and drives every call via asyncio.run, which doesn't survive a
live-HTTP integration test (per-call event loop vs. pooled
AsyncClient connections).
- specs/05-downstream-contract.md: documents two new entries under
"Backward compatibility — what changes":
* check_known_hosts now returns a generator on sync too (was a
list in 3.x due to the polymorphic-return trick; the docstring
already promised "Generator of IOC resources").
* Downloads buffer the full body in memory before chunking
(regression vs. requests-backed 3.x streaming).
- specs/99-open-questions.md: new entry "Streaming downloads —
HttpxResponseAdapter fully buffers" with concrete refactor proposal
(use client.stream + async-aware adapter); rewrote the "cassettes
that need an e2e refresh" entry to document why the 24 stale
cassettes can't be regenerated cleanly (hard-coded primary keys,
order-coupled state, count assertions on shared resources, missing
fixtures, eventual-consistency assertions, surviving server bugs).
Tests:
- Added respx test test_async_report_template_logo_delete pinning the
two-step flow (GET template → DELETE /reports/templates/logo?id=...).
Closes the gap the bot flagged: the upload + download paths already
had respx coverage; the delete path was VCR-only.
VCR cassettes:
- Round-2 re-record pass: deleted all cassettes, re-ran against the
live e2e. 23 cassettes regenerated cleanly under the new transport
+ the _input_json snapshot fix. 24 stay pinned to their prior
recordings — the corresponding tests aren't hermetic (hard-coded
IDs, order-coupled state, etc.). See specs/99-open-questions.md
for the full breakdown.
Sync mirrors regenerated; all 120 tests pass.
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.
No description provided.