Skip to content

sync(android): cherry-pick v2026.3.22 to Cat A cluster A1 — 23 files (#2582)#2595

Merged
alexey-pelykh merged 1 commit intomainfrom
chore/sync-cat-a1-android-2582
Apr 26, 2026
Merged

sync(android): cherry-pick v2026.3.22 to Cat A cluster A1 — 23 files (#2582)#2595
alexey-pelykh merged 1 commit intomainfrom
chore/sync-cat-a1-android-2582

Conversation

@alexey-pelykh
Copy link
Copy Markdown

Summary

Process Cat A cluster A1 of the v2026.3.22 upstream sync backlog: 31 fork files under apps/android/ requiring per-file disposition.

Action Count Notes
CHERRY-PICK applied (rebrand transform → fork content changes) 23 git diff shows real content changes
CHERRY-PICK no-op (already in sync after rebrand transform) 4 GatewayDiscovery.kt, Base64ImageState.kt, GatewaySessionInvokeTimeoutTest.kt, NodeHandlerRobolectricTest.kt
EXCLUDE-DIVERGENT (registered in hq/upstream/disposition.tsv) 4 See classification table below
Total 31 ✓ matches issue scope

Closes #2582.

EXCLUDE-DIVERGENT classifications

File Reason
chat/ChatController.kt gut #383 removed thinkingLevel/reasoningLevel session settings on fork; upstream still references them. Pre-classified by triage.
chat/ChatModels.kt gut #383. Pre-classified by triage.
NodeForegroundService.kt Upstream uses NodeApp.peekRuntime() (nullable) but fork's gutted NodeApp exposes non-null runtime only. Reclassified during execution.
ui/PostOnboardingTabs.kt Upstream calls MainViewModel.refreshHomeCanvasOverviewIfConnected() (new API); fork's gutted MainViewModel exposes requestCanvasRehydrate(source) instead. Reclassified during execution.

The 2 reclassifications match the 5–10% rate the issue body anticipated.

Approach

  1. Read upstream@v2026.3.22 content via git show v2026.3.22:{path}.
  2. Apply token-based rebrand transforms per hq/upstream/rebrand-tokens.tsv:
    • Path-dependent reverse-domain: ai.openclaw.apporg.remoteclaw.android (28 files) or org.remoteclaw.app (1 outlier Base64ImageState.kt + 1 outlier test NodeHandlerRobolectricTest.kt)
    • Generic transforms: OpenClawRemoteClaw, openclawremoteclaw, OPENCLAW_REMOTECLAW_, etc.
  3. Cross-class API audit (.tmp/audit-api-calls.py) detected 2 regressions (peekRuntime, refreshHomeCanvasOverviewIfConnected) → reverted those files, reclassified to EXCLUDE-DIVERGENT.

Three of 31 files target org/remoteclaw/app/ (per-file rebrand-map allows BOTH org.remoteclaw.android.* and org.remoteclaw.app.* package roots — fork is in transitional state). Documented; no consolidation in this PR.

Disposition.tsv updates

Four EXTRACT entries added at /Users/alexey-pelykh/RemoteClaw/hq/upstream/disposition.tsv (HQ companion, not in repo):

```
EXTRACT apps/android/app/src/main/java/ai/openclaw/app/NodeForegroundService.kt fork-divergent: upstream uses NodeApp.peekRuntime() (nullable); fork's gutted NodeApp exposes non-null `runtime` only — sync would require NodeApp API change (#2582)
EXTRACT apps/android/app/src/main/java/ai/openclaw/app/chat/ChatController.kt fork-divergent: gut #383 removed thinking/reasoning session settings on fork; upstream still references thinkingLevel/reasoningLevel (#2582)
EXTRACT apps/android/app/src/main/java/ai/openclaw/app/chat/ChatModels.kt fork-divergent: gut #383 removed thinking/reasoning session settings on fork (#2582)
EXTRACT apps/android/app/src/main/java/ai/openclaw/app/ui/PostOnboardingTabs.kt fork-divergent: upstream calls MainViewModel.refreshHomeCanvasOverviewIfConnected() (new API); fork's gutted MainViewModel exposes requestCanvasRehydrate(source) instead — sync would require MainViewModel API change (#2582)
```

Validation

Gate Result
`pnpm format:check` (oxfmt)
`pnpm tsgo` (TypeScript)
`pnpm lint` (oxlint)
`pnpm lint:tmp:no-random-messaging`
`pnpm lint:no-remoteclaw-ai`
`pnpm lint:ui:no-css-class-drift`
`bash scripts/ci/check-rebrand-leakage.sh --staged`
`node scripts/check-no-zombie-imports.mjs`
`node scripts/check-stub-debt.mjs` ✓ (126 == baseline)
`node scripts/check-throwing-stub-callers.mjs` ✓ (0 stubs)
`node scripts/check-obsolescence-audit.mjs` ✓ (49 == baseline)

Bulk verification: re-running cherry-pick script post-execution → 27 NOOP + 2 WRITE (the EXCLUDE-DIVERGENT files registered in disposition.tsv) → A1 residual = 0.

Note: Fork CI does not build Android (per `CLAUDE.md`). Local Android Gradle build NOT verified.

Polish review

`workflow-polish` ran in fresh subprocess context (session `fdb1cbd3-f9d1-4061-af8f-e187fea7d988`). Verdict: 🟢 CLEAN ENOUGH — no actionable findings. Two informational notes:

  1. `SelectedConnectAuth.authSource` field set but not read in `GatewaySession.kt` — preserves upstream parity.
  2. `mobileCardSurface`/`mobileCodeBorder` token references (added by upstream) are not yet defined in fork's `MobileUiTokens.kt`. The mirror `org/remoteclaw/app/ui/chat/ChatMessageViews.kt` on `origin/main` has the SAME dangling references — pre-existing fork gap, not introduced by this PR. Resolution belongs to a separate sync cluster.

Test plan

  • `pnpm check` passes locally
  • Fork-integrity gates pass locally
  • Per-file inspection: 27 CHERRY-PICK + 4 EXCLUDE-DIVERGENT = 31 covered
  • Polish review: CLEAN ENOUGH
  • CI green (pending)

🤖 Generated with Claude Code

…2582)

Process Cat A cluster A1 of the v2026.3.22 upstream sync backlog: 31 fork
files under apps/android/ requiring per-file disposition.

Disposition outcome:

| Action | Count |
|--------|------:|
| CHERRY-PICK applied (rebrand transform → fork content changes) | 23 |
| CHERRY-PICK no-op (already in sync after rebrand transform) | 4 |
| EXCLUDE-DIVERGENT (registered in hq/upstream/disposition.tsv) | 4 |
| Total | 31 |

EXCLUDE-DIVERGENT classifications:

- chat/ChatController.kt + chat/ChatModels.kt — gut #383 removed
  thinkingLevel/reasoningLevel session settings on fork; upstream still
  references them.
- NodeForegroundService.kt — upstream uses NodeApp.peekRuntime() (nullable)
  but fork's gutted NodeApp exposes non-null `runtime` only. Reclassified
  during execution per per-file inspection.
- ui/PostOnboardingTabs.kt — upstream calls
  MainViewModel.refreshHomeCanvasOverviewIfConnected() (new API); fork's
  gutted MainViewModel exposes requestCanvasRehydrate(source) instead.
  Reclassified during execution.

The 2 reclassifications match the 5–10% rate the issue body anticipated.

Approach:

1. Read upstream@v2026.3.22 content via `git show v2026.3.22:{path}`.
2. Apply token-based rebrand transforms per hq/upstream/rebrand-tokens.tsv —
   path-dependent reverse-domain (`ai.openclaw.app` → `org.remoteclaw.android`
   for 28 files / `org.remoteclaw.app` for 1 outlier file Base64ImageState.kt
   and 1 outlier test NodeHandlerRobolectricTest.kt) plus generic transforms
   (`OpenClaw` → `RemoteClaw`, `openclaw` → `remoteclaw`, `OPENCLAW_` →
   `REMOTECLAW_`, etc.).
3. Cross-class API audit detected 2 regressions (peekRuntime,
   refreshHomeCanvasOverviewIfConnected) → reverted those files,
   reclassified to EXCLUDE-DIVERGENT.

Validation gates: pnpm check (oxfmt, tsgo, oxlint, no-random-messaging,
no-remoteclaw-ai, css-class-drift), rebrand-gate, zombie-import-gate,
stub-debt-gate (126 == baseline), throwing-stub-callers-gate,
obsolescence-audit-gate (49 == baseline) — all PASS.

Note: Fork CI does not build Android (per CLAUDE.md). Local Android Gradle
build not verified.

Disposition.tsv updates land in /Users/alexey-pelykh/RemoteClaw/hq/ (HQ
companion, not in repo). Four EXTRACT entries with `fork-divergent: ...
(#2582)` rationale.

Closes #2582
@alexey-pelykh alexey-pelykh merged commit 31070dd into main Apr 26, 2026
16 checks passed
@alexey-pelykh alexey-pelykh deleted the chore/sync-cat-a1-android-2582 branch April 26, 2026 17:26
alexey-pelykh added a commit that referenced this pull request Apr 26, 2026
…2583) (#2596)

Process Cat A cluster A2 of the v2026.3.22 upstream sync backlog: 35 fork
files under apps/macos/ requiring per-file disposition.

Disposition outcome:

| Action | Count |
|--------|------:|
| CHERRY-PICK applied (rebrand transform → fork content changes) | 27 |
| EXCLUDE-DIVERGENT (registered in hq/upstream/disposition.tsv) | 4 |
| Total | 31 issue-listed |
| Helper files imported (net-new upstream additions referenced by cluster cherry-picks) | 15 |
| PairingAlertSupport refresh (refactored upstream — fork's older version replaced) | 1 |

Issue body listed 31 CHERRY-PICK + 4 EXCLUDE-DIVERGENT = 35. After per-file
inspection, all 4 of the 4 EXCLUDE-DIVERGENT entries were pre-classified by
triage and were not reclassified (rate: 0% reclassification — within the
5-10% the issue body anticipated). The 27/31 CHERRY-PICK count reflects
upstream content that genuinely diverges; the remaining 4 of 31 were NOOP
(fork already in sync after rebrand transform).

EXCLUDE-DIVERGENT classifications (all 4):

- apps/macos/Sources/OpenClaw/ContextUsageBar.swift
- apps/macos/Sources/OpenClaw/SessionMenuLabelView.swift
- apps/macos/Sources/OpenClaw/SessionsSettings.swift
- apps/macos/Sources/OpenClaw/UsageMenuLabelView.swift

All four trace to fork commit f7e9156 — gut(session): remove vestigial
contextTokens config and display denominator (#2277). Upstream still
references the gutted contextTokens symbols.

Approach:

1. Read upstream@v2026.3.22 content via `git show v2026.3.22:{path}`.
2. Apply token-based rebrand transforms per hq/upstream/rebrand-tokens.tsv —
   `OpenClaw → RemoteClaw`, `openclaw → remoteclaw`, `OPENCLAW → REMOTECLAW`,
   `OPENCLAW_ → REMOTECLAW_`, `ai.openclaw → org.remoteclaw`,
   `com.openclaw → org.remoteclaw`, `~/.openclaw → ~/.remoteclaw`,
   `.openclaw → .remoteclaw`, `openclaw-mac → remoteclaw-mac`,
   `@openclaw/ → @remoteclaw/`, `github.com/openclaw/openclaw → github.com/remoteclaw/remoteclaw`,
   `openclaw/openclaw → remoteclaw/remoteclaw`, `openclaw.io|openclaw.ai → remoteclaw.com`.
3. Cross-class API audit detected upstream extracted helper logic into
   13 net-new Swift files (PlatformLabelFormatter, SettingsRefreshButton,
   GatewayPushSubscription, JSONObjectExtractionSupport, TextSummarySupport,
   SimpleTaskSupport, TrackingAreaSupport, MicRefreshSupport,
   AgentWorkspaceConfig, SystemSettingsURLSupport, PermissionMonitoringSupport,
   VoiceOverlayTextFormatting, VoiceWakeRecognitionDebugSupport) plus
   1 in RemoteClawMacCLI (CLIArgParsingSupport) and 1 in shared kit
   (CaptureRateLimits). All 15 imported with rebrand transforms applied —
   they're net-new upstream additions referenced by cluster cherry-picks
   (not in audit's rebrand-below-threshold cluster lists because audit
   only flagged renames, not additions).
4. PairingAlertSupport.swift was refactored upstream — fork's older
   46-line version is replaced with upstream's 277-line refactor (with
   rebrand transforms applied) so cherry-picked NodePairingApprovalPrompter
   compiles. Fork's prior content (PairingAlertHostWindow, endActiveAlert,
   requireAlertHostWindow) is preserved verbatim by upstream's superset.

Notes:

- PeekabooBridgeHostCoordinator cherry-pick adds compatibility code that
  creates symlinks for upstream's pre-rebrand brand directory names
  (clawdbot, clawdis, moltbot). For fresh fork users these are no-op
  ghost directories. Polish reviewer agreed this is acceptable as
  literal upstream-parity (fork users have no pre-rebrand state per
  CLAUDE.md "User state boundary"). Optional follow-up: gate symlink
  creation behind fileExists check.
- Fork CI does not build macOS (per CLAUDE.md). Local Xcode build and
  swift test NOT verified — same caveat as merged Wave 1 PR #2595.

Closes #2583.

Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
alexey-pelykh added a commit that referenced this pull request Apr 26, 2026
#2584) (#2597)

Process Cat A cluster A3 of the v2026.3.22 upstream sync backlog: 10 fork
files under apps/shared/RemoteClawKit/ and apps/ios/Tests/. Mirrors merged
Wave 1 PR #2595 (A1 Android) and Wave 2 PR #2596 (A2 macOS).

Per-file dispositions:
- 7 CHERRY-PICK applied: ChatMarkdownPreprocessor.swift, ChatMessageViews.swift,
  ChatView.swift, Capabilities.swift, GatewayTLSPinning.swift,
  AssistantTextParserTests.swift, ChatMarkdownPreprocessorTests.swift
- 2 NOOP (already-synced after rebrand transform): ChatComposer.swift,
  GatewayNodeSession.swift
- 1 ALREADY-SYNCED reclassification: apps/ios/Tests/TalkConfigParsingTests.swift —
  cluster TSV's basename-search heuristic false-positive mapped fork's iOS path
  to upstream's shared-Kit variant; fork's existing content was already byte-
  identical to upstream apps/ios/Tests/Logic/TalkConfigParsingTests.swift +
  rebrand (and that upstream file is unchanged v2026.3.8 → v2026.3.22). No
  fork code change needed for this row. Discovered by polish.

0 EXCLUDE-DIVERGENT classifications (issue body anticipated 5–10%).

Net-new helper imports (2 files, transitive deps for cluster cherry-picks):
- AssistantTextParser.swift refresh — strict superset of fork's prior version,
  adds includeThinking parameter and visibleSegments helper. Fork's prior
  version had only a single rebrand: commit at #124. Required by the new
  ChatView/ChatMessageViews/AssistantTextParserTests cherry-picks.
- GenericPasswordKeychainStore.swift net-new import — pure utility, no fork-
  divergent specialization. Required by the new GatewayTLSPinning cherry-pick
  (UserDefaults → Keychain migration).

Mirrors Wave 2's 16 helper imports (15 net-new + PairingAlertSupport refresh).

Validation:
- pnpm format:check ✓
- pnpm tsgo ✓
- pnpm lint ✓
- pnpm lint:tmp:no-random-messaging ✓
- pnpm lint:no-remoteclaw-ai ✓
- pnpm lint:ui:no-css-class-drift ✓
- bash scripts/ci/check-rebrand-leakage.sh --staged ✓
- node scripts/check-no-zombie-imports.mjs ✓
- node scripts/check-stub-debt.mjs ✓ (126 == baseline)
- node scripts/check-throwing-stub-callers.mjs ✓ (0 stubs)
- node scripts/check-obsolescence-audit.mjs ✓ (49 == baseline)

Bulk verification: re-running cherry-pick script post-execution → WROTE=0
NOOP=9 → A3 residual = 0.

Note: Fork CI does not build Swift targets (per CLAUDE.md). Local Xcode/SPM
build NOT verified — same caveat as merged Wave 1 (#2595) and Wave 2 (#2596).

Polish review: workflow-polish ran in fresh subprocess context (session
cdca14ed-c46d-4540-b78d-77b5b53a46d3). Initial verdict 🟡 STALLED with
finding F1 (TalkConfigParsingTests basename misclassification). After
applying F1 Option A (revert + reclassify ALREADY-SYNCED), effectively 🟢
CLEAN with no remaining findings.

Closes #2584.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Process Cat A cluster A1 (Android, 31 files) — cherry-pick + EXCLUDE-DIVERGENT for v2026.3.22 sync backlog

1 participant