Skip to content

fix(asgi): emit per-request metrics from the pure-ASGI middleware - #164

Merged
rennf93 merged 1 commit into
masterfrom
fix/pure-asgi-request-metrics
Oct 15, 2026
Merged

rennf93 merged 1 commit into
masterfrom
fix/pure-asgi-request-metrics

Conversation

@rennf93

@rennf93 rennf93 commented Oct 15, 2026

Copy link
Copy Markdown
Member

Closes #163

The pure-ASGI middleware now records request metrics on the pass-through path when the response starts, matching the classic middleware: response_time stops at the response start, and the body is still streamed, never buffered. Tests in tests/test_asgi_pure.py cover allowed, error and streaming responses.

Gate: 452 passed, 100% branch coverage.

@github-actions github-actions Bot added the tests Test suite changes label Oct 15, 2026
@rennf93
rennf93 merged commit ce0fde6 into master Oct 15, 2026
13 checks passed
@rennf93
rennf93 deleted the fix/pure-asgi-request-metrics branch October 15, 2026 03:31
@rennf93 rennf93 mentioned this pull request Oct 15, 2026
2 tasks done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

tests Test suite changes

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[BUG] Pure-ASGI middleware never emits per-request metrics

1 participant