Skip to content

feat(runtime): bind continuation to accepted Gitoxide workspace heads - #42

Draft
zhiiw wants to merge 2 commits into
codex/managed-session-product-stack-v1from
codex/workspace-continuation-stack-v1
Draft

feat(runtime): bind continuation to accepted Gitoxide workspace heads#42
zhiiw wants to merge 2 commits into
codex/managed-session-product-stack-v1from
codex/workspace-continuation-stack-v1

Conversation

@zhiiw

@zhiiw zhiiw commented Aug 30, 2026

Copy link
Copy Markdown
Owner

Summary

Bind safe-boundary continuation to the exact accepted Gitoxide workspace head and prove that Host death does not replay an accepted Write/Edit or provider call.

This combines the old continuation extraction slice #39 into the final layer above #40 and #41.

Primary invariant

A continuation may start only when immutable Runtime history and immutable workspace history identify the same causal boundary: source run high-water, workspace epoch, execution profile, and accepted Git head.

  • Owner: Runtime owns continuation lineage and event high-water; the managed Session owner supplies the exact accepted workspace boundary.
  • Atomic boundary: continuation-start T1 binds the new Run to the authenticated source ledger prefix and workspace head before execution resumes.
  • Failure states: missing, stale, mismatched, cyclic, or unverifiable evidence parks the continuation. There is no silent downgrade to legacy resume.
  • Rollback/recovery: a started continuation is reconstructed from durable facts; accepted Write/Edit and provider results are adopted rather than replayed.

Scope

  • workspace-bound continuation envelope and strict validation
  • continuation lineage v2 binding
  • Session Manager admission and lifecycle wiring
  • exact accepted-head observation from the Gitoxide managed Session owner
  • Host-kill/restart crash tests for no provider replay

Verification

  • Core, Storage, Runtime, and Runtime Host builds pass.
  • Runtime continuation suite: 16 passed locally.
  • Six production-shaped Gitoxide helper/Host tests are explicitly environment-gated locally; they were not counted as passes. Building the real helper on this machine is blocked by a missing MSVC linker, not by source compilation.
  • git diff --check passes.

Stack: #40 -> #41 -> this PR.

中文说明

摘要

本 PR 将 safe-boundary continuation 绑定到精确的 accepted Gitoxide workspace head,并证明 Host 崩溃后不会重放已经接受的 Write/Edit 或 provider 调用。它把旧 #39 合并为 #40#41 之上的最终一层。

主要不变量

只有 immutable Runtime history 与 immutable workspace history 指向同一个 causal boundary 时,continuation 才能启动:source run high-water、workspace epoch、execution profile 与 accepted Git head 必须全部一致。

  • Owner: Runtime 拥有 continuation lineage 与 event high-water;managed Session owner 提供精确的 accepted workspace boundary。
  • 原子边界: continuation-start T1 在恢复执行前,把新 Run 绑定到经过认证的 source ledger prefix 与 workspace head。
  • 失败状态: evidence 缺失、过期、不匹配、成环或不可验证时一律 park;不会静默降级到 legacy resume。
  • 恢复方式: 已启动的 continuation 从 durable facts 重建;已接受的 Write/Edit 与 provider result 只 adopt,不重放。

本地四个 workspace 构建通过,Runtime continuation 测试 16 项通过。六个真实 Gitoxide helper/Host 用例因本机缺少可执行 helper 而明确 skip,没有冒充通过;本机 Rust 构建被缺失的 MSVC linker 阻塞。git diff --check 通过。

栈顺序:#40#41 → 本 PR。

This was referenced Aug 30, 2026
@zhiiw
zhiiw force-pushed the codex/managed-session-product-stack-v1 branch from 11ec993 to 2821eed Compare August 30, 2026 14:15
@zhiiw
zhiiw force-pushed the codex/workspace-continuation-stack-v1 branch from 3475205 to e8865db Compare August 30, 2026 14:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant