Repository navigation
test(j1939): witness actor disposal without elapsed margins - #472
Conversation
PR SummaryLow Risk Overview Adds an internal The in-actor Reviewed by Cursor Bugbot for commit d77d4e2. Bugbot is set up for automated code reviews on this repo. Configure here. |
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
Codecov Report✅ All modified and coverable lines are covered by tests. 📢 Thoughts on this report? Let us know! |
What does this change?
Refs #362 and its remaining timing inventory in comment 6357888413. Two J1939 disposal tests compared elapsed time against 1.5 seconds to distinguish a non-waiting actor call from a two-second join. Host scheduling could consume that margin.
The periodic-schedule case now keeps its emission blocked until the actor disposal call returns. An internal join-timeout seam retains the two-second production default; this test sets it to ten minutes so a mistaken self-join cannot finish within its hang guard. The actor DisposeAsync case inspects the returned ValueTask while still inside the actor turn: it must already be complete because the actual teardown is queued behind that turn. The test then awaits the real teardown from outside the actor.
Two restored source mutations fail at runtime: allowing the schedule to join its emission on the actor, and making actor DisposeAsync return the unfinished teardown task. No public API or default disposal behavior changes. #362 remains open for its other timing windows.
Type of change
feat— new behaviour (minor release)fix/perf— bug or performance fix (patch release)docs/test/refactor/chore/ci— no releaseChecklist
Validation: 3,035 net10 tests; net48 compilation; nine verified packages; 50 engineering tests; requirements traceability. The final Cobertura report was inspected across all classes and nested types: both changed executable entries are covered, with no missing lines or partial branches.