fix: release signature pins on stream cancellation - #1002
Conversation
Review · Status🟩 CompletedIronLoop completed the review and posted it to GitHub. ResultRun detailsAutomatic trigger · attempt 1 of 3 · completed in 5m 24s |
Review —
|
There was a problem hiding this comment.
Review · Summary
Found one remaining stream-cancellation pin leak in the legacy completions route.
Findings: 🟠 Medium 1
🟠 Medium · Clean up pins for legacy streaming completions too
/v1/completions is translated through the same chat streaming service, which pins the first chat ID. If its response body is dropped after a frame, the normal finalizer never runs and that route has no equivalent cancellation guard, so the provider’s chat-ID routing entry remains pinned. Apply the cleanup there as well, or centralize it in the stream owner, and add a dropped legacy-stream regression test.
Validation
- ✅ Chat stream cancellation path — Static tracing confirms the new guard stays owned by the chat-completions response body and is disarmed after normal finalization.
Review details
- Run:
6440e395-b2a6-4369-943b-d706de6ebf2b - Attempts: 1
|
✅ OpenCodeReview: Review failed: 0 finding(s); 2 of 2 selected item(s) failed. |
6230341 to
db4e6b2
Compare
7ac0086 to
63b6ec8
Compare
think-in-universe
left a comment
There was a problem hiding this comment.
Found one remaining cancellation edge case.
|
@ironloopai review |
Review · Status🟩 CompletedIronLoop completed the review and posted it to GitHub. ResultRun detailsManual command by think-in-universe · attempt 1 of 3 · completed in 21m 48s |
There was a problem hiding this comment.
Review · Summary
Found 1 medium-severity issue: canceled Responses API streams still leave provider-routing pins. The focused API end-to-end target compiled successfully; temporary local build artifacts were removed.
Findings: 🟠 Medium 1
Code-specific findings are attached to the diff.
Validation
- ✅ API end-to-end test target — Compiled successfully.
Review details
- Run:
4b5a18e5-6475-47c1-b6e4-52a6f1ac6c42 - Attempts: 1
63b6ec8 to
5d92d0c
Compare
5d92d0c to
c90085c
Compare
Summary
This is stacked on #1000.
Fixes #1001
Testing
cargo fmt --checkcargo clippy -p api --tests -- -D warningscargo test -p services completions:: --libcargo test -p api --libcargo test -p api --test e2e_all --no-runFocused E2E execution is blocked locally by PostgreSQL authentication during test bootstrap.