You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
fix(autoresearch): report a detach abandoned after repeated Ctrl-C (#5281 follow-up) - #5285
This fixes two CodeRabbit findings on #5284. They were posted after #5284 entered the merge queue, which locked its branch.
RpcBench._close_after_interrupt (r4617011198): if Ctrl-C keeps landing after the bounded resumes, the close task used to be dropped silently. It is now cancelled, and the bench prints [rpc] Ctrl-C repeated during detach; the serial session may still be attached. Driving the task forever would make repeated Ctrl-C impossible to exit.
Test (r4617011215): the double-interrupt test now counts the fake serial's close() calls and asserts exactly one, so a replacement close task cannot pass it.
Improved handling when a serial session is interrupted repeatedly. After three interrupts, the pending close operation is canceled and a warning is displayed that the session may remain attached before the event loop closes.
Added coverage confirming that the serial session’s detach operation is called once after a second interrupt.
No actionable comments were generated in the recent review.
Walkthrough
After three close attempts, RpcBench._close_after_interrupt cancels an unfinished close task and warns that the serial session may remain attached. The double-interrupt test now tracks close calls and asserts that detach is called once.
Changes: Interrupt cleanup
Layer / File(s)
Summary
Close task handling and test ci/autoresearch/rpc_bench.py, ci/tests/test_rpc_bench_liveness.py
After three close attempts, the cleanup path cancels an unfinished task and prints a warning. The test double counts close calls, and the double-interrupt test asserts that detach is called once.
FastLED/FastLED#5284: This PR updates the interrupt-cleanup path introduced and tested in that PR.
Merge Risk: Minimal · up to 002f7
This change makes repeated Ctrl-C during RPC benchmark cleanup exit cleanly and warn that the serial session may still be attached. It affects only CI benchmark tooling, and no merge-blocking risk was found.
Pre-merge checks: 4
Check name
Status
Explanation
Description Check
Check skipped - CodeRabbit’s high-level summary is enabled.
Title check
The title names the main change: the bench now reports when a detach is abandoned after repeated Ctrl-C, which matches the summary's cancel-and-warn behavior in RpcBench._close_after_interrupt. The co…
Linked Issues check
Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check
Check skipped because no linked issues were found for this pull request.
Full details: Title check
Explanation
The title names the main change: the bench now reports when a detach is abandoned after repeated Ctrl-C, which matches the summary's cancel-and-warn behavior in RpcBench._close_after_interrupt. The commit type and the #5281 follow-up reference are clear, and the title is specific to the change. The test change is secondary and is not named, which is acceptable.
Finishing Touches
Generate unit tests (beta)
Commit to this branch
Create a new PR
Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts
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.
Reviewing files that changed from the base of the PR and between 00c2703 and 002f757.
Files selected for processing: 2
ci/autoresearch/rpc_bench.py
ci/tests/test_rpc_bench_liveness.py
Included review availability: This review used your included allowance. Your plan provides up to 8 included reviews per hour; 4 remain after this review.
github-actionsBot
added
sanitized
Title, body and conversation screened; review text requires separate screening.
and removed
sanitized
Title, body and conversation screened; review text requires separate screening.
labels
Nov 18, 2026
github-actionsBot
added
sanitized
Title, body and conversation screened; review text requires separate screening.
and removed
sanitized
Title, body and conversation screened; review text requires separate screening.
labels
Nov 18, 2026
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
sanitizedTitle, body and conversation screened; review text requires separate screening.
1 participant
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.
Refs #5281, #5271, #5268
This fixes two CodeRabbit findings on #5284. They were posted after #5284 entered the merge queue, which locked its branch.
RpcBench._close_after_interrupt(r4617011198): if Ctrl-C keeps landing after the bounded resumes, the close task used to be dropped silently. It is now cancelled, and the bench prints[rpc] Ctrl-C repeated during detach; the serial session may still be attached. Driving the task forever would make repeated Ctrl-C impossible to exit.close()calls and asserts exactly one, so a replacement close task cannot pass it.Verification:
uv run pytest ci/tests/test_rpc_bench_liveness.py ci/tests/test_serial_interface_reset.pypasses (31 tests). ruff passes.Summary by CodeRabbit