Skip to content

fix(android): settle startup before checking archive refresh - #205891

Merged
vincentkoc merged 2 commits into
mainfrom
fix/android-archive-test-startup-settlement
Nov 26, 2026
Merged

vincentkoc merged 2 commits into
mainfrom
fix/android-archive-test-startup-settlement

Conversation

@vincentkoc

@vincentkoc vincentkoc commented Nov 26, 2026 •

Copy link
Copy Markdown
Member

What problem this solves

The Android archive refresh test can time out before it exercises pagination. In a controlled run, screenshot startup published its first session rows while a health-driven roster refresh was still pending. The first archive response was accepted, then the second read began before Compose displayed the settled ledger row.

Why this change was made

The fixture now waits for a snapshot of pending asynchronous work in the screenshot chat scope before it installs its archive responders. The wait is bounded at five seconds and covers the history bootstrap that awaits the roster refresh. All six per-action request counts, rendered-state assertions, and failure and pagination controls remain in the test.

User impact

This changes test setup only. Developers can exercise archive refresh under both ordinary startup and delayed roster delivery. It follows up on the earlier fixture repair. Previous Android test change

Evidence

API 34 Robolectric/Compose schedule Previous fixture Updated fixture
Ordinary startup Displayed ledger:false before the second read and passed all six read checks Same result
Roster reply delayed until the history request began First response accepted, second read held, five-second timeout before ledger:false Displayed ledger:false before the second read and passed all six read checks

The controlled replay used the checked-in test with a scoped runtime adapter. The exact trigger in the earlier hosted failures remains unknown.

Full Gradle results

The first signed head, fc543cbf, was tested on merge 83cf7f24. Both full unit-test jobs passed. Each class report executed archivedQueryRetainsOnlyItsOwnAcceptedPageAndReadsOncePerChange once with zero failures, errors or skips.

The same run found two required line breaks in the new Kotlin chain. Signed head eaca4c99 applies both. The configured ktlint check went from two diagnostics to zero, and the Kotlin syntax tree excluding whitespace was identical. Protected CI passed on the final head, including Android ktlint.

Both final Gradle jobs tested merge c830eb37, which contains signed head eaca4c99 on base d4cdcfc7. Each XML report recorded one execution of the archive refresh test with zero failures, errors or skips.

@vincentkoc vincentkoc self-assigned this Nov 26, 2026
@clawsweeper

clawsweeper Bot commented Nov 26, 2026 •

Copy link
Copy Markdown
Contributor

🦞👀
ClawSweeper picked this up.

Pull request received. I will update this pull request when review starts.

ClawSweeper review complete

ClawSweeper finished reviewing this revision. The review result is being finalized.

View the workflow run.

@vincentkoc
vincentkoc marked this pull request as ready for review November 26, 2026 09:59
@clawsweeper clawsweeper Bot added P3 Low-priority cleanup, docs, polish, ergonomics, or speculative work. clawsweeper:intake:bug Preliminary submission classification; full source review pending. clawsweeper:intake:needs-environment Preliminary submission classification; full source review pending. clawsweeper:intake:needs-repro Preliminary submission classification; full source review pending. labels Nov 26, 2026
@clawsweeper clawsweeper Bot added rating: 🦐 gold shrimp Decent PR readiness signal, but merge confidence is limited. status: 👀 ready for maintainer look ClawSweeper has no concrete contributor-facing blocker left for this PR. and removed clawsweeper:intake:bug Preliminary submission classification; full source review pending. clawsweeper:intake:needs-environment Preliminary submission classification; full source review pending. clawsweeper:intake:needs-repro Preliminary submission classification; full source review pending. labels Nov 26, 2026
@clawsweeper

clawsweeper Bot commented Nov 26, 2026 •

Copy link
Copy Markdown
Contributor

Codex review: needs maintainer review before merge.

What this changes

The Android archive-refresh test waits for pending startup reads before installing controlled responses.

Example: API 34 Robolectric startup delays the roster response until history loading begins.

  • Before: A late startup refresh can trigger the second archive request before ledger:false appears, stranding the test on its held response.
  • After: The fixture joins pending startup reads before installing archive responders, preserving the subsequent six request checks.

Review scores

Measure Result What it means
Overall readiness 🦐 gold shrimp (3/6) A focused, sound fixture repair with controlled in-process evidence and successful prior-head full suites; current-head CI remains pending.
Proof confidence 🦐 gold shrimp (3/6) No shipped behavior changes, so shipped-entry-point proof is unnecessary; the body records API 34 Robolectric schedules and linked full Gradle jobs confirm prior-head success.
Patch quality 🐚 platinum hermit (4/6) No actionable review findings were identified.

Product

Kind: Test only · Worth it: Yes · Fix scope: Complete
User problem: Android developers can hit a fixture timeout before archive pagination and refresh behavior are exercised.
Reason: The maintainer-authored change addresses an evidenced fixture schedule while preserving the test's production behavior coverage.

Merge readiness

✅ Ready for maintainer review

This PR makes a focused fixture repair without weakening archive assertions; no actionable defect remains in the reviewed head, and Android CI is still pending.

Reviewed head: eaca4c991c78277e73013f636e855b54c2e0104a

Before merge

None.

Findings

None.

Agent review details

How this fits together

The Robolectric fixture runs the Android runtime, chat controller, view model, and Compose archive state against controlled Gateway responses.

flowchart TD
  A[Screenshot runtime startup] --> B[Chat history bootstrap]
  B --> C[Health and roster refresh]
  C --> D[Bounded startup join]
  D --> E[Controlled Gateway responses]
  E --> F[Compose archive state]
  F --> G[Rendered state and request assertions]
Loading

Technical review

Best possible solution:

Keep the bounded fixture-only startup join and retain the existing archive behavior assertions.

Do we have a high-confidence way to reproduce the issue?

Source supports the reported startup overlap, and the body records a controlled red/green replay; the exact trigger of the earlier hosted failures remains unknown, and no tests were run during this read-only review.

Is this the best way to solve the issue?

The change synchronizes the existing fixture before request interception, preserves every behavioral assertion, and adds no production seam or competing owner.

AGENTS.md: found and applied where relevant.

Codex review notes: model internal, reasoning medium; reviewed against edfd93e8c82c.

Provenance checked

  • Archive-refresh fixture synchronization keeps the original intent (6a864bc: The Android personal-pin feature added archive state and request-count coverage; the subsequent merged fixture repair settled connection and owner projections before mounting.)

Testing

Proof path: in-process harness.

Security

None.

Evidence

What I checked:

Likely related people:

  • Vincent Koc: Raw commit d11cb05 adds apps/android/app/src/test/java/ai/openclaw/app/ui/SessionBrowserRefreshTest.kt:115 relative to its recorded parents. This identifies author metadata, not feature responsibility or a PR merger. (role: source-line author; confidence: high; commits: d11cb0518f09; files: apps/android/app/src/test/java/ai/openclaw/app/ui/SessionBrowserRefreshTest.kt)
  • Jason (Json): Raw commit 6a864bc adds apps/android/app/src/test/java/ai/openclaw/app/ui/SessionBrowserRefreshTest.kt:114 relative to its recorded parents. This identifies author metadata, not feature responsibility or a PR merger. (role: source-line author; confidence: high; commits: 6a864bcc9627; files: apps/android/app/src/test/java/ai/openclaw/app/ui/SessionBrowserRefreshTest.kt)

PR surface

Tests +13. Total +13 across 1 file. Added test files: 0.

View PR surface stats
Area Files Added Removed Net
Source 0 0 0 0
Tests 1 14 1 +13
Docs 0 0 0 0
Config 0 0 0 0
Generated 0 0 0 0
Other 0 0 0 0
Total 1 14 1 +13

Preflight source

Source unknown. Source comparison at the observed PR snapshot only. Completion is self-reported; body, policy, tests, execution, and report bytes are not verified.

Labels

Label changes:

No label changes.

Label justifications:

  • rating: 🦐 gold shrimp: Overall readiness is 🦐 gold shrimp; proof is 🦐 gold shrimp and patch quality is 🐚 platinum hermit.
  • status: 👀 ready for maintainer look: ClawSweeper has no concrete contributor-facing blocker left for this PR.

Rating scale

6/6 🦀 challenger crab · 5/6 🦞 diamond lobster · 4/6 🐚 platinum hermit · 3/6 🦐 gold shrimp · 2/6 🦪 silver shellfish · 1/6 🧂 unranked krab. Overall follows the weaker of proof and patch quality; ✨ marks media proof (a screenshot, video, or linked artifact) that directly shows the changed behavior.

Workflow

ClawSweeper edits this one comment on every review. Comment @clawsweeper re-review for a fresh review only. Repair and merge execution lanes are retired.

History

Review history (1 earlier review cycle)
  • reviewed 2026-11-26T10:14:31.297Z sha fc543cb :: needs maintainer review before merge. :: none

Reviewed November 26, 2026, 5:23 AM ET / 10:23 UTC (Revision 2).

@vincentkoc

Copy link
Copy Markdown
Member Author

@clawsweeper re-review

Please review eaca4c991c78277e73013f636e855b54c2e0104a. The only follow-up is the ktlint chain layout. The PR body links both full Gradle reports from the previous head.

@clawsweeper

clawsweeper Bot commented Nov 26, 2026 •

Copy link
Copy Markdown
Contributor

🦞👀
Exact review queued.

Re-review progress:

@vincentkoc
vincentkoc merged commit 0bea7ec into main Nov 26, 2026
89 checks passed
@vincentkoc
vincentkoc deleted the fix/android-archive-test-startup-settlement branch November 26, 2026 11:09
@vincentkoc

Copy link
Copy Markdown
Member Author

Merged via squash.

vincentkoc added a commit that referenced this pull request Nov 26, 2026
* commit '399057400013dcfa1923db08be96c6bf46cf7079':
  fix: keep known speakers on meeting notes with missing labels (#205923)
  fix(codex): let saved conversations recover after a remote failure (#201621)
  fix: distinguish namesakes in Google Meet transcript exports (#205915)
  refactor: share Discord meeting transcript publication (#205921)
  test: trim workflow and runtime performance coverage (#205782)
  fix(android): settle startup before checking archive refresh (#205891)
  fix: Gateway retains completed reply runtimes after catalog reloads (#195479)
  fix: clear unused-export failures in dependency checks (#205905)
  refactor: share browser routing for meeting captions and cleanup (#205916)
  fix(ui): update Workshop file preview mode (#205872)
  refactor(android): decouple shared JSON values from node handlers (#202840)
  fix(ci): remove bot credit from release notes (#205914)
  fix: pause interrupted shell turns when their result is unknown (#205859)
  fix(ui): skip publication options for removed workspaces (#205909)
  fix: preserve indentation in document previews (#205834)
  improve(ci): avoid full fixture builds for volume checks (#205903)
  refactor(android): derive connection readiness from its owner (#202898)
vincentkoc added a commit that referenced this pull request Nov 26, 2026
…oid-chat-preview-grapheme-boundary

* commit '0bea7ecb3029583dd49d83f760d4f40c9e1f543c': (129 commits)
  fix(android): settle startup before checking archive refresh (#205891)
  fix: Gateway retains completed reply runtimes after catalog reloads (#195479)
  fix: clear unused-export failures in dependency checks (#205905)
  refactor: share browser routing for meeting captions and cleanup (#205916)
  fix(ui): update Workshop file preview mode (#205872)
  refactor(android): decouple shared JSON values from node handlers (#202840)
  fix(ci): remove bot credit from release notes (#205914)
  fix: pause interrupted shell turns when their result is unknown (#205859)
  fix(ui): skip publication options for removed workspaces (#205909)
  fix: preserve indentation in document previews (#205834)
  improve(ci): avoid full fixture builds for volume checks (#205903)
  refactor(android): derive connection readiness from its owner (#202898)
  fix: preserve side chat text when dictating at the limit (#205710)
  improve(telegram): polling workers start faster and use half the memory (#190890)
  fix: keep speaker identities distinct in meeting notes (#205860)
  fix: wait for cancellation before releasing ACP test preparation (#205893)
  fix: bound workers retained after deleting sessions across agents (#197409)
  fix(memory): keep a child's memory audience after its parent resets (#205887)
  refactor(android): give installed skills one data owner (#202892)
  fix(cli): share process failure listeners across invocations (#205732)
  ...
github-actions Bot pushed a commit to Desicool/openclaw that referenced this pull request Nov 27, 2026
…w#205891)

* test(android): settle startup reads before archive responses

* style(android): wrap archive fixture startup chain
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

app: android App: android P3 Low-priority cleanup, docs, polish, ergonomics, or speculative work. rating: 🦐 gold shrimp Decent PR readiness signal, but merge confidence is limited. size: XS status: 👀 ready for maintainer look ClawSweeper has no concrete contributor-facing blocker left for this PR.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant