Seal managed workspace baseline admission - #1872
Conversation
|
Addressed the remaining M0 admission blocker and the CI-only assertion failure in
Local verification: 中文说明已在
本地验证:core/storage build 通过;real-Git M0 suite 16 通过、5 个 Windows 能力限制跳过;Biome 与 |
|
Follow-up from the new Linux CI run ( The final fence now uses a root-identity guard captured from the authenticated lease during owner construction. This preserves both invariants:
The existing owner-drain regression and the new post-commit marker-replacement regression both pass locally. A new CI run has started. 中文说明新的 Linux CI 暴露了一个生命周期细节:最初的最终检查重新要求 active lease,虽然能抓住 marker 替换,却会误杀 现在改为在 owner 构造时,从已认证 lease 捕获 root identity guard,并在最终返回前调用。这样同时保持两条不变量:
现有 owner drain 测试与新增 post-commit marker replacement 测试均已在本地通过;新的 CI run 已启动。 |
|
CI is now fully green on head 中文说明当前 head |
|
有一个当前会阻止合并的 SQLite migration 冲突需要处理: PR head 但最新 因此这里不能只做普通的 conflict resolution,否则可能出现
我本地用 |
35f0c74 to
9c75013
Compare
|
Resolved the schema-number collision and rebased the PR onto current
Verification:
中文说明已解决 migration 编号冲突,并把 PR 变基到当前
最终变基后,schema、runtime store 与多进程并发测试 48/48 通过;managed baseline/owner、recovery persistence、workspace authority 与 crash/recovery 定向套件也已通过。本机 Windows 按设计跳过需要 POSIX crash/symlink 能力的用例。 |
9c75013 to
af976c7
Compare
|
Rebased once more onto current The six failing storage cases were not new failures in the managed-workspace change: they were migration-fixture and backup-error expectations already corrected on main by #2016. Replaying this PR onto current main brings those fixes in without duplicating them here. Post-rebase verification:
中文说明在 storage CI 失败后,已再次变基到当前 六个失败并不是 managed workspace 改动引入的新回归,而是 main 后续 #2016 已修复的 migration fixture 与 backup error 断言问题。此次通过变基直接继承 main 的修复,没有在本 PR 中复制补丁。 变基后:core/storage build 通过;此前失败的 intent claim、supervisor wake、session migration、operational backup 用例已通过;runtime schema/store 与 SQLite 多进程并发用例通过,其中包含 populated v8 → v9 升级测试。唯一的本地失败是 Windows 执行 POSIX sandbox path fixture 的既有平台差异,与本 PR diff 无关; |
af976c7 to
b3fc207
Compare
|
Resolved the latest main conflict and rebased #1872 onto The only content conflict was the SQLite multiprocess child fixture. The resolution preserves both sides of the contract:
Verification after the rebase:
中文说明已解决最新 main 冲突,并将 #1872 变基到 唯一的内容冲突位于 SQLite 多进程 child fixture。解决时同时保留了两侧契约:
变基后 core/storage build 通过;runtime schema + runtime store 37/37 通过;SQLite 多进程并发 12/12 通过,同时覆盖 fresh operational WAL 并发初始化和 baseline admission 并发; |
Summary
Seal the M0 managed-workspace baseline admission boundary by composing the merged Git artifact owner and Workspace Version Authority behind one public owner.
ManagedWorkspaceOwner.openManagedWorkspaceBaseline(); artifact-only creation and raw receipt issuance remain package-internal.runtime.sqliteto the authenticated storage root's durablerootIdin schema 8; a copied database, replaced marker, hard link, symlink, or pathname replacement fails closed.Why
The merged foundation PRs establish two independent authorities: Git owns managed artifacts, while immutable RuntimeEvents own runtime acceptance. M0 is the narrow composition gate that proves both authorities describe the same workspace boundary before any worktree becomes usable.
The previous integration branch bound the SQLite file location but not the database content's durable storage-root identity. Copying
runtime.sqlitefrom root A to root B could therefore pass pathname and inode checks. This flat rebuild adds a singleton durable root binding and validates it in the same transaction as baseline acceptance.Invariant and boundaries
For one authenticated storage root and workspace epoch, a caller receives a managed worktree only after:
rootId;Any mismatch fails closed. There is no attached-workspace fallback and no Desktop/CLI/runtime-host consumer in this PR.
ManagedWorkspaceOwnerScope limits
This PR does not expose managed worktrees to tools, modify the user's checkout, implement workspace mutation/version advancement, support ignored dependency environments, or enable automatic resume. Those remain later slices.
This is a flat rebuild from
upstream/main@bb44e37e6after #1742 and #1743 merged; it does not merge or cherry-pick the historical integration branch.Validation
git diff --checkpassed on all changed production/test files.Linux/macOS CI remains the release proof for POSIX SIGKILL, symlink, inode-replacement, whole-root import/adopt, and non-UTF-8 Git-path cases that are skipped or capability-limited on Windows.
中文说明
概要
本 PR 完成 managed workspace M0 的 baseline admission 组合边界:把已经合并的 Git artifact owner 与 Workspace Version Authority 收敛到唯一 public owner 后面。
ManagedWorkspaceOwner.openManagedWorkspaceBaseline();artifact-only 创建与 raw receipt 发行保持 package-internal。runtime_storage_root_binding将runtime.sqlite内容绑定到 authenticated storage root 的 durablerootId;单独复制数据库、替换 marker、hard-link、symlink 或 pathname replacement 全部 fail closed。核心不变量
调用者只有在以下四项全部成立后才能得到 managed worktree:
rootId绑定;任何不一致都 fail closed;本 PR 不提供 attached fallback,也不接入 Desktop、CLI 或 runtime-host。
范围边界
本 PR 不把 managed worktree 暴露给工具,不修改用户 checkout,不实现 workspace mutation/version advancement,不处理 ignored dependency environment,也不启用自动 resume。这些属于后续切片。
本分支从
upstream/main@bb44e37e6平铺重建;没有 merge 或 cherry-pick 历史 integration branch。验证
git diff --check。POSIX SIGKILL、symlink、inode replacement、whole-root import/adopt 与 non-UTF-8 Git path 的最终发布证据由 Linux/macOS CI 承担。