test(android): poll for stale TLS probe cleanup in auth test#83826
Conversation
|
Codex review: needs real behavior proof before merge. Reviewed July 1, 2026, 2:25 AM ET / 06:25 UTC. Summary PR surface: Other +16. Total +16 across 1 file. Reproducibility: no. I did not establish a high-confidence flaky failure against current main. Source inspection shows current main still uses a fixed post-disconnect sleep around an async TLS probe, so the flake claim is plausible but not directly reproduced. Review metrics: none identified. Merge readiness Overall follows the weaker of proof and patch quality, so missing proof can cap an otherwise strong patch. Rank-up moves:
Proof guidance:
Risk before merge
Maintainer options:
Next step before merge
Security Review findings
Review detailsBest possible solution: Keep the PR focused on this Android test, but wait on stale TLS probe coroutine completion or an explicit skipped-stale-attempt signal before final assertions, then add redacted after-fix Robolectric proof. Do we have a high-confidence way to reproduce the issue? No, I did not establish a high-confidence flaky failure against current main. Source inspection shows current main still uses a fixed post-disconnect sleep around an async TLS probe, so the flake claim is plausible but not directly reproduced. Is this the best way to solve the issue? No. Polling null pending trust and desired bootstrap state is not the best fix because disconnect clears those values synchronously; the test should wait on a barrier tied to the stale probe coroutine being consumed or skipped. Full review comments:
Overall correctness: patch is incorrect AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning high; reviewed against 0c7bac34ae68. Label changesLabel justifications:
Evidence reviewedPR surface: Other +16. Total +16 across 1 file. View PR surface stats
What I checked:
Likely related people:
What the crustacean ranks mean
Shiny media proof means a screenshot, video, or linked artifact directly shows the changed behavior. Runtime, network, CSP, and security claims still need visible diagnostics. How this review workflow works
|
|
Heads up: this PR needs to be updated against current |
Signed-off-by: NeatGuyCoding <15627489+NeatGuyCoding@users.noreply.github.com>
Co-authored-by: NeatGuyCoding <15627489+NeatGuyCoding@users.noreply.github.com>
6d6b077 to
a6c794e
Compare
|
Land-ready proof for exact head
Proof gap: no emulator screenshot is applicable because this is a test-only synchronization change with no runtime/UI behavior. |
|
Merged via squash.
|
…w#83826) * test(android): poll for stale TLS probe cleanup in auth test Signed-off-by: NeatGuyCoding <15627489+NeatGuyCoding@users.noreply.github.com> * test(android): await stale TLS probe job Co-authored-by: NeatGuyCoding <15627489+NeatGuyCoding@users.noreply.github.com> --------- Signed-off-by: NeatGuyCoding <15627489+NeatGuyCoding@users.noreply.github.com> Co-authored-by: Peter Steinberger <steipete@gmail.com>
…w#83826) * test(android): poll for stale TLS probe cleanup in auth test Signed-off-by: NeatGuyCoding <15627489+NeatGuyCoding@users.noreply.github.com> * test(android): await stale TLS probe job Co-authored-by: NeatGuyCoding <15627489+NeatGuyCoding@users.noreply.github.com> --------- Signed-off-by: NeatGuyCoding <15627489+NeatGuyCoding@users.noreply.github.com> Co-authored-by: Peter Steinberger <steipete@gmail.com>
What Problem This Solves
GatewayBootstrapAuthTest.connect_ignoresStaleTlsProbeAfterDisconnectused a fixed 100 ms delay before checking that a completed TLS probe could not restore stale connection state. That timing assumption made the test vulnerable to scheduler and runner load.Why This Change Was Made
The final test snapshots the runtime scope's existing child jobs, starts the delayed TLS probe, identifies the single newly created probe job, and joins that exact job after disconnecting and completing the probe. Assertions therefore run only after the stale-attempt guard has executed, without a production-only test seam or a poll on fields that
disconnect()clears synchronously.User Impact
No runtime behavior change. This makes the Android TLS recovery regression test deterministic and reduces CI flakiness.
Evidence
GatewayBootstrapAuthTest: 21 tests passed, 0 failures.git diff --checkpassed.a6c794e218b1b4c0b626c46de685e6f596a16abc.