Summary
services::chat_impl::tests::concurrent_streams::cancel_emits_event_only_for_target can fail after a cold build, then pass repeatedly without source changes.
Observed behavior
During local verification, the test failed twice immediately after a cold compile. It then passed in nine consecutive reruns, including a six-run stress loop.
Suspected cause
The test drains a capacity-16 global broadcast event bus with a while let Ok(...) = try_recv() pattern. If the receiver reports Lagged, that loop stops before reaching the event under test. Concurrent tests can publish enough events to make this timing-dependent.
Expected behavior
The test should distinguish an empty receiver from a lagged receiver and continue draining after lag, or use isolated event capture so unrelated concurrent events cannot make the assertion flaky.
Scope note
No production behavior failure was observed. This issue tracks test reliability only; no unrelated changes were included in the stream-failure fix where the flake was encountered.
Summary
services::chat_impl::tests::concurrent_streams::cancel_emits_event_only_for_targetcan fail after a cold build, then pass repeatedly without source changes.Observed behavior
During local verification, the test failed twice immediately after a cold compile. It then passed in nine consecutive reruns, including a six-run stress loop.
Suspected cause
The test drains a capacity-16 global broadcast event bus with a
while let Ok(...) = try_recv()pattern. If the receiver reportsLagged, that loop stops before reaching the event under test. Concurrent tests can publish enough events to make this timing-dependent.Expected behavior
The test should distinguish an empty receiver from a lagged receiver and continue draining after lag, or use isolated event capture so unrelated concurrent events cannot make the assertion flaky.
Scope note
No production behavior failure was observed. This issue tracks test reliability only; no unrelated changes were included in the stream-failure fix where the flake was encountered.