Commit Graph
83992 Commits
Author SHA1 Message Date
Peter Steinberger d65e712b28 feat(macos): enable native node session hosting (#131717)
* feat(macos): enable native node session hosting

Complete the app-owned node worker connection lifecycle and honor explicitly admitted Full access without bypassing node-local restrictions. Preserve one node identity, native capabilities, approval lifetime, and exact placement/turn authority.

* test(nodes): exercise canonical exec policy flows

* refactor(macos): remove obsolete node bridge serializer

* fix(nodes): bind Full authority to harness execution commands
2026-08-28 07:11:12 -07:00
Peter Steinberger 83dce46a7d fix(update): preserve sealed service definitions during code updates (#131021)
Separate code-update ownership, effective launcher identity, native service control, and definition mutation. Guard actual definition publication before related config or token writes, and use the installed CLI's preserve-definition restart with renewed ownership and live port/version/build verification.

Consolidate unit/environment publication and conditional rollback, retain main's plugin convergence and fresh-Doctor ownership, and make post-core child termination belong to the winning completion path. Integrate current-main heap-argument provenance and process-marker handling; resolve the service Node from the executable rather than counting backward through flags.

Retain boundary-level sealed/writable/unknown/foreign, mount, platform, failure, and build-identity proof while consolidating redundant tests. The QA cleanup removes 399 maintained test/support lines; focused current-main integration proof passes 1,279 tests with one pre-existing platform skip. Production and installer growth remains +239 net.

Preserves the reviewed repair from ac86fdff61da9c0fea9f62da00a8c9f22df6790d while integrating main at 56d89073dd. No permission weakening, schema or lease policy change, deployment, or release.
2026-08-28 07:10:42 -07:00
xingzhouandAyaan Zaidi b56a7b4390 fix(ui): isolate multi-pointer gesture ownership (#118591)
Bind resize and browser annotation gestures to their initiating pointer so foreign input cannot mutate or end them. Capture loss and panel lifecycle cleanup now commit or release the owned interaction once.

Co-authored-by: zhang-guiping <zhang.guiping@xydigit.com>
Co-authored-by: Ayaan Zaidi <hi@obviy.us>
2026-08-28 19:40:34 +05:30
Peter Steinberger f40e5f27a0 fix(test): prepare runtime before plugin batch readers (#131778) 2026-08-28 07:00:56 -07:00
Sally O'Malley a696e4f687 fix(openshell): preserve overlapping workspace uploads (#131556)
Signed-off-by: sallyom <somalley@redhat.com>
2026-08-28 09:49:09 -04:00
c749244de1 fix(cli): preserve source resolution outside checkout (#131479)
* fix(cli): honor checkout cwd in agent shim

* fix(cli): preserve caller cwd in agent shim

* fix(cli): escape agent shim tsconfig paths

* test(cli): cover source invocation resolution outside checkout

* test(cli): preserve native Windows launcher failure evidence

* fix(cli): preserve source invocation outside checkout

Co-authored-by: gaoanze <gaoanze@meituan.com>

* style(cli): format source invocation repair

Co-authored-by: gaoanze <gaoanze@meituan.com>

---------

Co-authored-by: gaoanze <gaoanze@meituan.com>
Co-authored-by: Peter Steinberger <steipete@gmail.com>
2026-08-28 06:48:45 -07:00
Leon-SK668andAyaan Zaidi 1bfcb71584 fix(sms): redact reflected Twilio credentials (#119963)
A reflected upstream error could expose Twilio Basic credentials. Redact bounded error bodies once at the shared SMS transport boundary while preserving provider diagnostics.

Co-authored-by: Leon-SK668 <0668001470@xydigit.com>
Co-authored-by: Ayaan Zaidi <hi@obviy.us>
2026-08-28 19:16:06 +05:30
Vincent Koc 1186e6a6f3 feat(release): seal full release candidate evidence (#131751)
* feat(release): seal full release candidate evidence

* fix(release): harden candidate evidence validation

* test(release): cover candidate digest tuples

* fix(release): retain candidate tooling closure

* test(ci): refresh release candidate guard inventories

* test(release): decouple candidate workflow fixture
2026-08-28 21:44:21 +08:00
5edb54e616 fix(agents): keep option-only Code Mode configs disabled (#131407)
* fix(agents): require explicit code mode activation

Restore the stable default so Code Mode stays disabled unless enabled is explicitly true or auto.

Worked on by:
- @VACInc

Co-authored-by: VACInc <3279061+VACInc@users.noreply.github.com>

* test(ui): stabilize typography picker changes

---------

Co-authored-by: roboclaw-bot <309084314+roboclaw-bot@users.noreply.github.com>
Co-authored-by: VACInc <3279061+VACInc@users.noreply.github.com>
2026-08-28 06:42:19 -07:00
xingzhouandAyaan Zaidi af74c9c0e0 fix(agents): keep fallback turns cancellable (#126566)
Preserve one active cancellation and terminal owner across model fallback so primary failures cannot strand running tasks.

Co-authored-by: zhang-guiping <zhang.guiping@xydigit.com>
Co-authored-by: Ayaan Zaidi <hi@obviy.us>
2026-08-28 19:10:59 +05:30
Peter Steinberger 0c35375958 fix(cron): distinguish intentionally suppressed deliveries (#131774)
Use the recorded suppression reason for human list and show status while preserving genuine delivery warnings and JSON contracts. Related: #111851. Thanks to @akalsey for the report.
2026-08-28 06:40:13 -07:00
Peter Steinberger 60dcc53827 chore(deps): refresh seven-day-cooled runtimes and tooling (#131719)
* chore(deps): refresh cooled runtimes and tooling

Refresh selections published strictly before 2026-08-21T02:01:28Z while preserving inherited dependency identities and existing policy.

* fix(build): keep meeting CLI metadata dependency-light

Keep Teams and Zoom metadata discovery out of the meeting runtime graph, preserve CLI descriptors and output modes, and remove the unused factory that has not shipped in a stable release. Import-boundary regressions fail before the repair; all 21 focused tests and normal metadata generation pass without changing render deadlines or concurrency.

Defer the OpenShell dependency bump until its separately owned host-gateway fixture repair is available. Retain the existing version and installer reference; do not ship a policy or test workaround.

* test(cli): type-check meeting metadata registrations

* test(plugins): sync CLI metadata snapshot mocks

Cover the config-wide snapshot and projection exports used by the current main runtime load context. The original fixture failed 19 of 25 tests after the progressive cache update (#131442); all 25 now pass on both main and this candidate without changing production behavior or assertions.
2026-08-28 06:38:50 -07:00
Vincent Koc 17a1225314 fix(release): preserve publish evidence identity (#131782) 2026-08-28 21:37:10 +08:00
wangmiao0668000666andAyaan Zaidi 1530b6b80e fix(acpx): strip Bedrock prefix from Claude ACP model refs (#121105)
Translate canonical Amazon Bedrock model refs at the Claude ACP adapter boundary so startup and model-control send native Bedrock identifiers.

Co-authored-by: wangmiao0668000666 <wang.miao86@xydigit.com>
Co-authored-by: Ayaan Zaidi <hi@obviy.us>
2026-08-28 19:05:02 +05:30
22d4279245 fix(tui): surface provider auth failures (#125677)
Make local TUI auth failures actionable while preserving the foreground child lifecycle, provider picker routing, and built-in token masking under custom redaction patterns.

Co-authored-by: Timur Turatbekov <timatur242005@gmail.com>
Co-authored-by: Ayaan Zaidi <hi@obviy.us>
2026-08-28 19:00:56 +05:30
openclaw-mantis[bot]andgithub-actions[bot] 968945a0f1 chore(ui): refresh control ui locales (#131755)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2026-08-28 13:28:49 +00:00
wanyongstarandAyaan Zaidi babb2fc7c1 fix(agents): preserve replies after plugin non-delivery (#125706)
Plugin-native suppressed, dry-run, and failed message results remain eligible for a final assistant reply. Sent results continue to suppress duplicate replies.

Co-authored-by: 万拥 0668000723 <wan.yong@xydigit.com>
Co-authored-by: Ayaan Zaidi <hi@obviy.us>
2026-08-28 18:45:53 +05:30
Peter Steinberger cb696a1bb3 test(gateway): preserve native request policy in wire capture (#131758) 2026-08-28 06:07:21 -07:00
Heming ZengandAyaan Zaidi 5b072470f1 fix(cron): prevent stale current-session results after reset (#127854)
Keep current-session cron completions attached to the source lifecycle generation so resets do not accept stale output.

Co-authored-by: Heming Zeng <hermanzeng@foxmail.com>
Co-authored-by: Ayaan Zaidi <hi@obviy.us>
2026-08-28 18:35:47 +05:30
Peter Steinberger b03d2e79e9 fix(sessions): prevent participant misattribution in Activity (#130986)
* fix(sessions): preserve participant identity and input provenance

Keep profile, agent, remote, observed, and legacy identities distinct in the existing participant table. Record accepted input at admission, including steering, instead of inferring a person from the session creator. Preserve historical membership and counts while leaving ambiguous profile timestamps unknown through stopped-writer Doctor migration.

Project full visibility-filtered person membership before preview limits so Activity does not misattribute channel identities or omit people outside the facepile. Keep participant membership separate from authorization and expose raw-selector ambiguity to memory operators.

Repair Doctor readiness reporting, generic Swift inline-union generation, direct-dispatch metadata handling, and fixture-owned database lifetimes. Verify namespace collisions, real provider input, accepted steering, visibility, backup/migration/reopen boundaries, native decoding, and the built-CLI lifecycle.

Fixes #130661

* fix(macos): isolate readiness and discovery lifecycles

Keep readiness fixtures private for their entire lifetime and give health readiness one deadline owner. Start and cancel slow host discovery with active discovery, not model construction.

Make native protocol, callback, onboarding, and process-cleanup tests observe their intended lifecycle phases without expanding deadlines or weakening assertions. Correct the documented signing default.

Validated with 1,839 parallel native tests, the release product build, causal negative controls, pinned Swift lint/format checks, and fresh isolated autoreview. Native production delta: -5 lines.

* docs(macos): clarify app profile isolation boundaries

* build(protocol): refresh generated Swift install models

* fix(protocol): preserve optional literal field presence

* fix(ci): bound SDK declarations and isolate test lifecycles

Discover the current declaration source graph in a joined child before normal eager emission, and track its complete source-bearing cache inputs. Repair shared jsdom focus teardown and native worker fixture request ordering without changing UI focus ownership or execution fallback policy.

* test(sessions): prove Goal participant upgrade boundaries
2026-08-28 06:04:18 -07:00
Peter Steinberger b6aff3ef0e test(ui): measure scroll interruption at native pointer arrival (#131763) 2026-08-28 05:51:59 -07:00
Vincent Koc 571be95d06 refactor(lobster): use resumed flow identity on failure (#131499) 2026-08-28 20:51:01 +08:00
468054f93c fix(agents): surface Claude OAuth expiry in channels (#131345)
Classify the dependency-owned Claude CLI OAuth expiry as authentication so channel users receive the existing re-authentication steps. Preserve resumable-session recovery for other CLI providers, missing provider metadata, and real stale conversation IDs.

Co-authored-by: Marvinthebored <peter@lindsey.jp>
Co-authored-by: Ayaan Zaidi <hi@obviy.us>
2026-08-28 18:03:07 +05:30
Vincent Koc 1454c60c18 fix(release): install cross-os baseline validation deps (#131756) 2026-08-28 20:28:25 +08:00
Vincent Koc ccbbaf2e2e fix(ci): accept broker-owned Crabbox identity (#131754) 2026-08-28 20:21:07 +08:00
Peter Steinberger 4267631456 test(infra): share npm install environment fixtures (#131749) 2026-08-28 05:12:08 -07:00
xingzhouandPeter Steinberger 0e16f347ea fix(code-mode): host-policy denial no longer triggers read-only recovery (#131007)
* fix(code-mode): preserve ordinary recovery after host denial

Record exact host-owned operation no-start and preserve it through subscriber completion. Keep whole-cell mutation containment and attribute the temporary recovery instruction to OpenClaw.

Fixes #130274. Thanks to @tylerbrevard for the report.

Co-authored-by: zhang-guiping <zhang.guiping@xydigit.com>

* test(agents): await raw-stream append completion

---------

Co-authored-by: Peter Steinberger <steipete@gmail.com>
Co-authored-by: zhang-guiping <zhang.guiping@xydigit.com>
2026-08-28 05:05:55 -07:00
Peter Steinberger b029a959db fix(update): avoid declaration build timeouts on dev updates (#131746) 2026-08-28 05:05:34 -07:00
Peter Steinberger d7e280fcf6 fix(http): deliver body rejection responses before closing uploads (#131724)
* fix(http): deliver body rejection responses before closing uploads

Centralize bounded rejection transport and ordered connection admission, preserving Node response framing, upgrade flow ownership, and Feishu anomaly diagnostics. Remove duplicate request teardown and expose the shared custom-envelope rejection helper. Related: #126808, #126818.

* test(http): keep rejection fixtures typed and scoped

Prove queued responses exist before use and move the abort-activity test into its own file with shared signing/account fixtures. Preserve all wire assertions and clarify the Node HEAD callback contract.

* fix(http): preserve incoming request ownership across consumers
2026-08-28 05:01:17 -07:00
Peter Steinberger 07ed8f27b0 refactor(agents): remove unused failover classifier compositions (#131732) 2026-08-28 04:59:03 -07:00
70c44ce84d perf: per-delta cost grows with concurrent agent count because every delta walks every run's event listeners (#129174)
* perf(agents): index agent-event listeners by run instead of walking every run's closures

emitAgentEvent notified one process-global listener Set. Five subscribers
register a listener whose first statement discards other runs, so at N
concurrent runs every assistant delta walked N run-scoped closures to do useful
work in one of them - O(N) per delta, O(N^2) fleet-wide.

Add a runListeners bucket beside the global Set plus onAgentEventForRun, and
convert the five per-run sites (openai-http, openresponses-http,
cli-backend-dispatch, system-agent/agent-turn, acp-spawn-parent-stream), keeping
their runId guard as a harmless second check. Globals are notified first and
keep stock ordering; empty buckets are dropped on unsubscribe.

agent-job.ts stays global: it filters on stream, not runId.

* perf: route the shared CLI delivery bridge and approval wait through the run bucket

createAgentEventBridge and observeAgentRunApprovalWait still subscribed with
onAgentEvent and discarded foreign runs as their first action, so they kept the
per-delta cost this branch removes. The bridge is the highest-volume instance:
one CLI dispatch builds eight bridges from that shared factory, so N concurrent
runs left 8N run-filtered closures on the global set.

Both now subscribe with onAgentEventForRun. Their runId guards stay as a
fail-closed second check, matching the six sites already converted here.

Five remaining onAgentEvent callers are genuinely process-global (agent-job,
subagent registry, task registry lifecycle, plugin runtime bridge, TUI backend)
and are left alone.

* test(gateway): cover concurrent streamed agent events

Exercise token-authenticated Chat Completions and Responses streams through
the real Gateway, agent loop, local provider, WebSocket events, and agent.wait.
Expose existing startup diagnostics within the isolated test fixture.

Keep approval-wait subscriptions on the existing global path pending owner
review. This reduces the converted listeners' fanout but does not close the
remaining concurrency-dependent fanout issue.

Co-authored-by: Tran Quang <randytran8800@gmail.com>

* test: capture agent event ordering regressions

Exercise nested emission and unsubscribe through the real delivery bridge.
Prepare the existing runtime artifacts for the concurrent Gateway proof,
and correct its lint and formatting failures without changing its budget.

This diagnostic stage intentionally preserves the candidate dispatcher
until CI captures the ordering regressions; it is not ready to land.

Co-authored-by: Tran Quang <randytran8800@gmail.com>

* fix: preserve live order in run-indexed agent events

Merge global and matching-run subscriptions by registration order while
preserving live mutations, nested dispatch, and unsubscribe semantics.
Cover the observed delivery regressions and interleaved bridge isolation.
Run the authenticated concurrent-stream proof through the existing built
Gateway process harness with exact-checkout artifact provenance.

Related: #129173

Co-authored-by: Tran Quang <randytran8800@gmail.com>

* style: satisfy event dispatch lint rules

Use non-mutating sorting for the fresh listener cohort, initialize the
unsubscribe binding at its existing assignment, and distinguish unused
mapper parameters without changing the proved behavior or assertions.

Co-authored-by: Tran Quang <randytran8800@gmail.com>

---------

Co-authored-by: Peter Steinberger <steipete@gmail.com>
Co-authored-by: Tran Quang <randytran8800@gmail.com>
2026-08-28 04:58:47 -07:00
Peter Steinberger adfe56e302 fix(control-ui): preserve inherited reasoning after history refresh (#131613)
* fix(control-ui): preserve inherited reasoning after history refresh

* fix(gateway): scope prepared thinking policy to history

* fix(gateway): keep profile history metadata nonblocking

* fix(ci): isolate catalog discovery ordering from worker startup

* chore(ci): defer ingress lint repair to merged owner fix
2026-08-28 04:55:10 -07:00
Peter Steinberger 2059ea9dfc fix(codex): persist every completed pre-steer assistant item in steering history (#131606)
* fix(codex): persist every completed pre-steer assistant item in steering history

The steering transcript prefix reused the final-answer selection barrier,
so a steer consumed after a tool or sleep barrier persisted only the
latest eligible completed assistant item. Earlier completed items stayed
in the gateway run buffer with no durable row, and after a reload the
UI's persisted-prefix subtraction could not cover them — already-seen
pre-steer output re-rendered below the operator's steering message.

Final-answer selection and steering history are different concerns: the
steering path now collects every completed, terminal-eligible, visible
assistant item in chronological order, each with its mirror identity so
repeats across subsequent steers deduplicate. Final-answer candidate
selection, its exclusion tests, terminal-result handling, and the buffer
projection are unchanged. Net +1 production line.

Regressions: four barrier scenarios (none/sleep/dynamic-tool/native-tool)
fail pre-fix losing pre-steer items; snapshot mirror-identity coverage;
UI history recovery of the split after reload.

* fix(codex): keep assistant-message options caller-owned in steering collection

Restores the caller-supplied AssistantMessageOptions contract the boundary
picker had, and tightens the collection return. Also brings the file back
under the max-lines cap that check-lint enforces (the inlined options
object pushed it two counted lines over).

* test(ui): share steering recovery fixtures across identities
2026-08-28 04:52:26 -07:00
Peter Steinberger c85129f855 fix(codex): keep native overrides effective at launch and turn start (#131745)
* fix(codex): keep native overrides effective at launch and turn start

Preserve native CLI argument ordering and temporary-root exclusions across
launch and turn preparation, including commented TOML booleans.

Fixes #131741.

* fix(codex): remove type-only launch configuration cycle

Import the existing launch options contract directly, preserving identical
runtime output while removing the config barrel dependency cycle.
2026-08-28 04:43:16 -07:00
Vincent Koc d3a5f2333e fix(ci): allow crabbox proof across forward main (#131738) 2026-08-28 19:41:40 +08:00
70eb4a71ac fix(ui): usage page stays loading after cache rebuild (#108270)
Co-authored-by: Alex Knight <15041791+amknight@users.noreply.github.com>
Co-authored-by: Peter Steinberger <steipete@gmail.com>
2026-08-28 04:39:48 -07:00
Peter Steinberger c792a16791 fix(agents): allow uncategorized hidden and ACP spawns (#131736) 2026-08-28 04:37:44 -07:00
Vincent Koc 789e81162b perf(release): expose Windows upgrade timing evidence (#131727) 2026-08-28 19:37:30 +08:00
Vincent Koc c28cb02384 fix(release): resume failed validation without repeating green jobs (#128141)
* fix(release): resume failed FRV child attempts

* fix(release): harden FRV continuation controller

* fix(release): bind FRV continuation source evidence

* fix(release): support historical FRV source evidence

* fix(release): bind historical FRV source inputs

* fix(release): bind historical FRV source evidence

* fix(release): preserve historical FRV source identity

* fix(release): align FRV continuation CI checks

* fix(release): disable fail-fast for FRV continuations

* test(release): align FRV fail-fast expectation

* fix(release): classify missing FRV artifacts centrally

* fix(release): recover FRV state from workflow artifacts

* fix(release): overwrite recovered FRV plan artifact

* docs(release): clarify FRV plan recovery

* fix(release): harden FRV continuation recovery

* fix(release): revalidate FRV tooling ref before dispatch

* fix(release): authenticate historical FRV plans

* fix(release): fail FRV when temporary ref cleanup fails

* test(ci): update FRV workflow routing expectations

* fix(release): declare FRV workflow ref helper

* fix(release): keep FRV recovery on the same parent

* fix(release): verify original dispatch on parent recovery
2026-08-28 19:35:10 +08:00
Peter Steinberger ca59305029 fix(gmail): keep setup command failures readable (#131502)
* fix(gmail): keep setup command failures readable

* test(gmail): consolidate setup diagnostics coverage

* docs(ci): clarify Swift test execution policy

* test(brave): cancel requests at the transport boundary

The in-flight cancellation fixture polled for fetch within one second, but
first-use runtime and DNS preparation can exceed that deadline. The first
case then exited without aborting or awaiting its request, leaking it into
the next case's global fetch mock (CI run 33118704789).

Abort from the existing mocked transport after its listener is registered,
await terminal rejection, and retain exact call-count and aborted-signal
assertions. No production behavior, timeout, or SDK mock changes.

(cherry picked from commit 697040a81eeb26a8ea947cec01b544125c3d98c0)

* test(openshell): keep mirror socket fixtures within platform limits

The wrapper's canonical macOS temp root makes the nested socket fixture
exceed the 104-byte sockaddr_un.sun_path field, failing at listen before
mirror reconciliation. Shorten the existing temporary-directory prefix
without changing the socket name, assertions, cleanup, or production code.

* refactor(channels): reuse ingress stop guard
2026-08-28 04:33:50 -07:00
Peter Steinberger 047470456f feat(control-ui): create and manage goals without slash commands (#131370)
* feat(control-ui): create and manage goals without slash commands

* fix(control-ui): keep goal composer contracts acyclic

* refactor(control-ui): tighten goal composer guidance

* fix(goals): admit fresh and completed local sessions

Create the first session with its Goal, input, run claim, and receipt in the existing transaction. Scope reply dispatch hooks consistently at admission and execution, and retain built-in runtime eligibility after completed turns. Preserve creator and lifecycle checks and cover the failures observed through the real Control UI flow.

* fix(ui): preserve button names during fade-in

* docs: defer Goal release notes to release generation
2026-08-28 04:31:48 -07:00
Vincent Koc 240b485326 fix(release): bound FRV polling cadence (#131714) 2026-08-28 19:31:25 +08:00
Michael AppelandJacob Tomlinson 16c35b2df8 fix: persist hidden completion wake provenance (#126329)
Co-authored-by: Jacob Tomlinson <jtomlinson@nvidia.com>
Co-authored-by: Michael Appel <mappel@nvidia.com>
2026-08-28 12:29:33 +01:00
Peter Steinberger ad189b0a53 fix(ui): prevent duplicate answers while runs finish (#131681)
Keep persisted assistant answers visible once while workspace reconciliation is still finishing. Reconcile durable same-run prefixes at persistence and delta ingress, preserve stream baselines, and publish error-terminal answers through the transcript reducer without hiding workspace failures.

Fixes #131671. The separate malformed non-prefix stream observation remains outside this repair.
2026-08-28 04:28:48 -07:00
Peter Steinberger b45cf37368 refactor(channels): split claim-write retries out of ingress-drain (#131742)
Recently landed #127849 and #127950 grew ingress-drain.ts past the
max-lines cap between each other's CI runs, so every merge ref now fails
check-lint-core-4. Move the bounded claim-write retries and the
complete/release/dead-letter wrappers into ingress-claim-writes.ts —
byte-identical functions, unchanged public surface and behavior — taking
the file from 703 to 625 counted lines with headroom, no suppression.
2026-08-28 04:24:59 -07:00
Vincent Koc 56d89073dd fix(test): make state DB eviction assertion deterministic (#131725) 2026-08-28 19:19:33 +08:00
640d73e3d4 fix(anthropic): reload compacted Claude sessions (#131288)
* fix(anthropic): reload compacted SDK sessions

* test(cache): require 90% Anthropic embedded hit rate

Worked on by:
- @VACInc

Co-authored-by: VACInc <3279061+VACInc@users.noreply.github.com>

* test(cache): align Anthropic API cache floor

* test(cache): run embedded Anthropic parity probe

* test(cache): enforce Anthropic API hit-rate parity

---------

Co-authored-by: VACInc <3279061+VACInc@users.noreply.github.com>
Co-authored-by: roboclaw-bot <309084314+roboclaw-bot@users.noreply.github.com>
2026-08-28 07:05:22 -04:00
Vincent Koc c07b753819 refactor(channels): move ingress settlement owner (#131731) 2026-08-28 19:02:35 +08:00
Peter Steinberger 90a9622a6c refactor(test): centralize fixture cleanup and invalid-input cases (#131709) 2026-08-28 03:52:51 -07:00
3f749b97ca fix(update): route stored dev channel to the git update flow [AI-assisted] (#123083)
* fix(update): route stored dev channel to the git update flow [AI-assisted]

A package-detected launcher with a stored update.channel: dev resolved the
npm "dev" dist-tag (which does not exist -> ETARGET) because switchToGit
only honored an explicitly requested --channel dev. Base the decision on
the effective channel and collapse the duplicated selectedChannel/channel
computation, which is provably identical in every reachable case.

Refs #123073

* docs(update): state the dev-channel git contract in the routing comment

Review finding: "dev" can exist as a rare npm dist-tag, so the comment
must not claim it never does; the routing rationale is the documented
dev-channel git-checkout contract.

* fix(update): keep one-off --tag on the package path for stored-dev installs

--tag is documented as a one-run package-target override, so a stored dev
channel must not divert a tagged update into the git flow (where the tag
is ignored). An explicitly requested --channel dev still outranks the tag,
matching existing explicit-channel behavior.

* test(update): scope the package-to-git clone to a per-case OPENCLAW_GIT_DIR

The stored-dev routing case performs a real transactional clone. On the
default <home>/openclaw that directory outlived the case and made a later
test fail with "OPENCLAW_GIT_DIR appeared while cloning".

Test Plan: node --import tsx scripts/test-projects.mts src/cli/update-cli.test.ts
Failing set now matches clean origin/main exactly (3 pre-existing macOS
$TMPDIR symlink failures, unrelated to this change).

Assisted by an AI coding assistant; reviewed before submitting.

* test(update): verify stored dev routing on installed packages

Temporary expected-failure verification for #123073. Restore only the routing owner to its pre-fix bytes while retaining the original contributor commits and adding installed-package regression coverage. This head must not merge; restore the reviewed fix and require hosted green proof after capturing the intended failure.

* fix(update): restore stored dev routing after regression proof

Restore the contributor's canonical effective-channel fix after the
installed-package regression lane reproduced package routing for stored
dev. Keep one-off tags on the package path and explicit dev precedence.

Remove the obsolete source-text assertion now covered by installed CLI
behavior and format the CI documentation table. Preserve all original
contributor commits. Fresh hosted GREEN validation remains required.

Co-authored-by: Chinmayrawat15 <chinmayrawat15@gmail.com>

---------

Co-authored-by: Peter Steinberger <steipete@gmail.com>
Co-authored-by: Chinmayrawat15 <chinmayrawat15@gmail.com>
2026-08-28 03:52:36 -07:00