feat(runtime): establish the managed mutation acceptance kernel - #40
Draft
zhiiw wants to merge 13 commits into
Draft
feat(runtime): establish the managed mutation acceptance kernel#40zhiiw wants to merge 13 commits into
zhiiw wants to merge 13 commits into
Conversation
… re-login (apache#3358) * fix(desktop): show the Codex device sign-in code on connection-detail re-login The connection detail sheet's re-login notice drives the same browser-assisted OAuth flow as the provider catalog panel, but never rendered the flow's stateHint. For Codex that hint is the 9-digit device user code the authorization page requires — the verification URL does not embed it — so a re-login started from the notice could never be completed. - OAuthLoginService gains showsDeviceCode: true for Codex, false for xAI, whose page needs no manual code (mirrors the catalog panel's !isXai guard). The mapping stays in use-connection-detail so the legacy AppShell closure gains no file and no dependency. - OAuthReloginNotice appends the sign-in code to the banner description while authorization is pending, reusing the catalog's deviceCode copy. Fixes apache#3357 Generated-by: Claude Code (Fable 5) Co-Authored-By: Claude Fable 5 <noreply@anthropic.com> * chore(deps): normalize locked npm registry sources (apache#3381) Replace stale Microsoft 1ES proxy resolutions with the canonical npm registry tarballs while preserving the exact package versions. Refresh their integrity metadata to npm-published SHA-512 digests so clean installs no longer depend on an unrelated proxy. Generated-by: Codex --------- Co-authored-by: Claude Fable 5 <noreply@anthropic.com> Co-authored-by: Wang <m4n5terrr@gmail.com>
This was referenced Aug 30, 2026
This was referenced Aug 30, 2026
Add production-reachable Storybook coverage for empty activity, capped many-session summaries, long generated reports, and failed generation archives.\n\nRefs apache#3944 and apache#3893.
Seventh surface under apache#3944 (one surface per PR): the Agent Graph panel had no Storybook story. Add its failure and edge states, mounted through a scoped `window.maka.graphs` bridge inside the real composer host seam (.maka-detail-with-artifacts → .mainColumn), each pinning one AgentGraphClientSnapshot. - EmptyGraph — graph mode enabled, no operators yet: the panel's empty state. - FailedGraph — a failed operator beside completed/running ones. - BlockedOnUpstream — a blocked operator with the amber "waiting for input" line. - ManyOperators — a wide fan-out (28 operators) with no fabricated omitted count (the read-model only elides operators past 256) — review feedback. - LoadError — the IPC snapshot read rejects: the panel's error Banner + Retry. The panel renders operators as a flat list (no edges/hierarchy), so tree depth and cycles have no distinct rendering and are left out. Plays assert reachability of each state; exact row counts / omitted lines are read-model contracts left to the read-model's own tests (review feedback). Refs apache#3944, apache#3893 Generated-by: Claude Code
Sixth surface under apache#3944 (one surface per PR): extend the chat transcript (ChatView → materializeTurns → TurnView, via Product/Shell Official AppShell) with the failure and edge states that never show up in normal use. All feed a real message ledger through ComposedShell, like InterruptedToolAfterTurnAbort. - FailedTurnWithToolError — a tool call errors mid-turn and the turn settles `failed`: the errored tool row plus the failed Banner + erroredTool description. - ProviderRateLimited — a settled `failed` turn with errorClass 'rate_limit'. - ProviderRetrying — a live turn whose providerRetry swaps the working phrase for the ModelProviderRetryIndicator banner. - SafeResumeAfterRestart — the last turn failed with errorClass 'app_restarted', offering the warning-severity Banner with the 继续这一轮 safe-resume button. - ManyTurns — 120 turns, past the transcript virtualizer's window (review feedback: 20 did not guarantee the virtualization path). Streaming, aborted/interrupted, empty, and long-message states were already covered, so this adds only the genuinely missing ones. All are safe presentational states driven by the message ledger and live overlay. Refs apache#3944, apache#3893 Generated-by: Claude Code
* refactor(runtime): remove unvalidated Auto tool guidance Remove the prompt fragment, composition wiring, export, and feature-specific tests added by apache#3705. Maka has no demonstrated retry-loop reproduction or A/B evidence for this guidance, and the implemented best-fit wording does not match the issue’s CLI-first premise. Generated-by: OpenAI Codex * test(core): remove speculative sanitizer coverage Remove the direct sanitizer matrix added by apache#3692. It was not tied to a reported regression, planned behavior change, or failing contract, while existing session-name and foreign-session tests continue to cover the real trust-adjacent behavior. Generated-by: OpenAI Codex
Canonicalize Seatbelt roots through the deepest existing ancestor so writable roots and explicit denies share one path namespace. Fail closed on permission errors, symlink loops, and other non-missing canonicalization failures.
* fix(desktop): connect shared sessions through Peer Mesh Join managed Runtime Hosts through explicit Client and Host Mesh targets, recover stale authority routes over management channels, and expose managed Host Mesh actions directly. Persist signed endpoint and Mesh names, keep stable identifiers copyable, and make Mesh rosters collapsible without exposing internal revisions. Generated-by: Codex * fix(peer): connect Mesh members to managed Hosts Activate Relay v2 reservations when transit policy is added to an existing peer connection, and preserve native path failures as stable errors. Keep managed endpoint metadata and signed routes atomic while tightening the Desktop management boundary. Generated-by: OpenAI Codex * fix(cli): accept managed Mesh operator context Allow the generic managed-service operator launcher to pass its validated client data root through Peer Mesh commands, so Desktop can reconcile managed Hosts instead of failing during argument parsing. Generated-by: OpenAI Codex * fix(peer): recover Mesh routes through reachable members Generated-by: OpenAI Codex * fix(desktop): make peer collaboration recoverable * fix(peer): preserve active Mesh transport paths * fix(desktop): recover interrupted managed Host setup * fix(desktop): activate managed Host Peer Mesh * fix(cli): replace incompatible development Hosts * refactor(desktop): isolate Runtime Host management UI * test(runtime-host): finalize owner pairings explicitly * fix(desktop): make Peer Mesh refresh local and bounded * style(cli): format Runtime Host setup changes * docs(astryx): refresh surface inventory
zhiiw
force-pushed
the
codex/managed-write-edit-stack-v1
branch
from
August 30, 2026 14:06
cc194db to
a6bf8f3
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Establish the managed mutation kernel that owns the durable boundary from T1 reservation through terminal settlement and atomic SQLite successor acceptance.
This PR intentionally stops before Gitoxide candidate reopening and accepted-ref repair. Those recovery and projection responsibilities now live in a second stacked delivery so this PR has one primary invariant:
Ownership
Atomic boundary
For a successful mutation, SQLite commits the tool outcome, workspace successor fact, canonical head CAS, and reservation release in one transaction. For no-change or a proven no-effect business failure, SQLite commits the terminal outcome and reservation release without advancing the head.
Failure and retry states
The no-effect bearer is now bound to its issuing owner, concrete execution store, and durable storage-root identity. Runtime also constructs the terminal outcome once and uses that same immutable event for live publication and durable settlement.
Follow-up boundary
The stacked Gitoxide recovery PR owns durable candidate receipt reopening, accepted-ref projection, active-reservation recovery state, and production-shaped helper crash evidence. It does not widen this PR's SQLite or Runtime authority.
Verification
upstream/main.git range-diffpreserved all six extracted commits exactly.git diff --checkpasses.中文说明
摘要
本 PR 只建立 managed mutation kernel,负责从 T1 reservation 到 terminal settlement 与 SQLite 原子 successor acceptance 的 durable 边界。
Gitoxide candidate 重开与 accepted-ref 修复已经移到第二个 stacked PR。本 PR 只证明一个主要不变量:
Owner
原子性与失败状态
成功 mutation 在一个 SQLite transaction 中提交 tool outcome、workspace successor fact、canonical head CAS 与 reservation release。no-change 或已证明无副作用的业务失败只提交 terminal outcome 并释放 reservation,不推进 head。
缺少证明或证明冲突时 fail closed,禁止 generic fallback。no-effect capability 已绑定签发 owner、具体 execution store 与 durable storage-root identity;Runtime 只构造一次 terminal outcome,live publication 与 durable settlement 使用同一 immutable event。
后续边界
第二个 stacked Gitoxide recovery PR 负责 durable candidate receipt 重开、accepted-ref projection、active reservation recovery state 与真实 helper crash evidence,不会扩大本 PR 的 SQLite/Runtime 权限。
验证
本分支已从最新
upstream/main重建;六个 extraction commits 经range-diff全部精确保留;Core、Storage、Runtime、Runtime Host 构建通过;mutation/settlement/persistence 定向测试通过;跨 store 伪造 no-effect capability 会被拒绝;git diff --check通过。