Skip to content

fix(android): stop saved gateway reconnect CI flake#101519

Merged
steipete merged 1 commit into
mainfrom
codex/android-gateway-refresh-test
Jul 7, 2026
Merged

fix(android): stop saved gateway reconnect CI flake#101519
steipete merged 1 commit into
mainfrom
codex/android-gateway-refresh-test

Conversation

@steipete

@steipete steipete commented Jul 7, 2026

Copy link
Copy Markdown
Contributor

What Problem This Solves

Resolves an Android CI flake where the saved-gateway reconnect test could fail when runtime auto-connect raced the test's explicit connection setup.

Why This Change Was Made

The test now follows the real runtime lifecycle: await the saved gateway's automatic connection, rotate its stored credential, disconnect, refresh, and await the new desired connection. This removes the duplicate test-owned connection without weakening the reconnect assertion.

User Impact

No runtime behavior changes. Android PRs get deterministic coverage that refresh reconnects the saved endpoint with current stored credentials.

Evidence

@steipete steipete self-assigned this Jul 7, 2026
@openclaw-barnacle openclaw-barnacle Bot added app: android App: android size: XS maintainer Maintainer-authored PR labels Jul 7, 2026
@clawsweeper

clawsweeper Bot commented Jul 7, 2026

Copy link
Copy Markdown
Contributor

ClawSweeper status: review started.

I am starting a fresh review of this pull request: fix(android): stop saved gateway reconnect CI flake This is item 1/1 in the current shard. Shard 0/1.

This placeholder means the worker is alive and reading the current context. I will edit this same comment with the actual review when the claws are done clicking.

Crustacean status: shell secured, claws on keyboard, evidence pebbles being sorted.

@steipete

steipete commented Jul 7, 2026

Copy link
Copy Markdown
Contributor Author

Land-ready proof:

  • Root cause: the test seeded an active gateway before NodeRuntime construction, then raced runtime auto-connect with a second explicit connection and immediately inspected desired session state.
  • Fix: await the real saved-gateway auto-connect, rotate persisted credentials, disconnect, refresh, and await the replacement desired connection before checking endpoint and token.
  • Focused proof: GatewayBootstrapAuthTest.refreshGatewayConnection_reconnectsSavedManualEndpointAfterDisconnect passed on Blacksmith Testbox through Crabbox (tbx_01kwxxm7jg9b2qgmzhmzkkn0mv).
  • Exact-head CI: https://github.com/openclaw/openclaw/actions/runs/28855360219 — Play and third-party unit tests, Play/third-party APK build and lint, benchmark build, and ktlint all passed at 25c4076ff3fff3237b448c6f82c6a3504034a887.
  • Review: .agents/skills/autoreview/scripts/autoreview --mode local --engine codex --model gpt-5.5 --thinking high --stream-engine-output returned no accepted/actionable findings.
  • Proof gaps: none for this test-only change.

@steipete
steipete merged commit 9cd29dc into main Jul 7, 2026
68 of 71 checks passed
@steipete
steipete deleted the codex/android-gateway-refresh-test branch July 7, 2026 09:30
@steipete

steipete commented Jul 7, 2026

Copy link
Copy Markdown
Contributor Author

Merged via squash.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

app: android App: android maintainer Maintainer-authored PR size: XS

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant