You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@maka.apache.org by "zhiiw (via GitHub)" <gi...@apache.org> on 2026/08/30 12:37:40 UTC

[PR] feat(runtime): establish durable Gitoxide Write/Edit acceptance [maka]

zhiiw opened a new pull request, #4265:
URL: https://github.com/apache/maka/pull/4265

   ## Summary
   
   Establish the exact managed Write/Edit mutation path on top of the merged Gitoxide repository authority and accepted-tree data plane.
   
   This combines the previously reviewed extraction slices #30-#35 into one delivery unit. It does not carry the old integration-branch history.
   
   ## Primary invariant
   
   After managed T1 is durable, one exact operation over one accepted base can produce only one immutable Gitoxide candidate and one SQLite-accepted successor. Runtime must never fall back to a generic outcome writer or replay the filesystem side effect.
   
   - **Owner:** Runtime owns the immutable operation result; Storage owns acceptance; Gitoxide owns candidate content and accepted-ref projection.
   - **Atomic boundary:** T2, successor fact, canonical workspace head, and reservation release commit in one SQLite transaction.
   - **Failure states:** deterministic no-effect terminal, accepted successor, or unsettled/parked. No silent fallback.
   - **Rollback/recovery:** unaccepted candidates remain derived artifacts; exact retries adopt immutable evidence and do not re-run Write/Edit.
   
   ## Scope
   
   - mutation argument authority and bounded strict-JSON result snapshot
   - pure Write/Edit transform over accepted Git content
   - durable candidate proof and retry identity
   - managed settlement and SQLite successor acceptance
   - accepted-ref projection and projection recovery
   - owner-bound no-effect capabilities
   - focused crash/reopen and exact-retry coverage
   
   ## Verification
   
   - Core, Storage, Runtime, and Runtime Host builds pass.
   - Focused mutation/settlement/owner tests pass (48 passed; one environment-gated real-helper test skipped locally).
   - `git diff --check` passes.
   
   This remains Draft while the stacked product-composition and continuation PRs are reviewed.
   
   <details>
   <summary>中文说明</summary>
   
   ## 摘要
   
   本 PR 在已合并的 Gitoxide repository authority 和 accepted-tree 数据面之上,建立完整且严格绑定的 managed Write/Edit mutation 链路,并把此前 #30-#35 的 extraction slice 合并为一个可审查交付单元;不会携带旧 integration branch 的历史。
   
   ## 主要不变量
   
   managed T1 持久化后,同一个 accepted base 上的一次确定操作,只能产生一个 immutable Gitoxide candidate 和一个 SQLite accepted successor。Runtime 不得回退到 generic outcome writer,也不得在恢复时重新执行 Write/Edit 副作用。
   
   - **Owner:** Runtime 拥有 immutable operation result;Storage 拥有 acceptance;Gitoxide 拥有 candidate content 和 accepted-ref projection。
   - **原子边界:** T2、successor fact、canonical workspace head 与 reservation release 在一个 SQLite transaction 中提交。
   - **失败状态:** 确定的 no-effect terminal、accepted successor,或 unsettled/parked;禁止静默 fallback。
   - **恢复方式:** 未接受的 candidate 只是派生 artifact;精确重试采用 immutable evidence,不重新执行 Write/Edit。
   
   ## 验证
   
   Core、Storage、Runtime、Runtime Host 均构建通过;定向 mutation/settlement/owner 测试通过;本地只有一个需要真实 helper 环境的测试显式跳过;`git diff --check` 通过。
   
   本 PR 暂保持 Draft,等待其上的产品组合与 continuation 两层栈一起完成审查。
   
   </details>
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@maka.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@maka.apache.org
For additional commands, e-mail: commits-help@maka.apache.org


Re: [PR] feat(runtime): establish the managed mutation acceptance kernel [maka]

Posted by "zhiiw (via GitHub)" <gi...@apache.org>.
zhiiw commented on PR #4265:
URL: https://github.com/apache/maka/pull/4265#issuecomment-5707464612

   Closing this Draft in favor of a fresh implementation on current main. PR #5287 intentionally removed the unconnected managed Runtime path; we will not restore that old path through conflict resolution. The existing branch and review history remain extraction references. The replacement will adapt Storage authority to current lifecycle ownership and deliver managed Write/Edit with a real consumer and crash evidence. No replacement PR is ready yet.
   
   <details>
   <summary>中文说明</summary>
   
   关闭本 Draft,后续基于最新 main 重建。#5287 已主动删除未接线的 managed Runtime 路径,不通过解冲突恢复旧实现。保留原分支与审查历史作为提取来源;新实现会适配当前 Storage 生命周期,并将 managed Write/Edit 与真实消费者、崩溃证据一起交付。Desktop 首版计划在加号菜单提供显式入口,与 Plan、Swarm 同级。替代 PR 尚未就绪。
   
   </details>


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@maka.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@maka.apache.org
For additional commands, e-mail: commits-help@maka.apache.org


Re: [PR] feat(runtime): establish the managed mutation acceptance kernel [maka]

Posted by "zhiiw (via GitHub)" <gi...@apache.org>.
zhiiw commented on PR #4265:
URL: https://github.com/apache/maka/pull/4265#issuecomment-5469186285

   Thanks — I agree with the ownership diagnosis, but I have kept the delivery at two PRs rather than splitting it into four smaller protocol fragments.
   
   The stack is now organized as follows:
   
   1. **This PR: managed mutation acceptance kernel**
      - Runtime owns one bounded immutable result and one terminal response event.
      - The no-effect bearer is scoped to its issuer, concrete execution store, and durable storage-root identity.
      - SQLite owns reservation arbitration and the atomic terminal/successor transaction.
      - Generic T2 remains forbidden after managed T1.
   
   2. **Stacked recovery PR: [zhiiw/maka-agent#43](https://github.com/zhiiw/maka-agent/pull/43)**
      - Active T1 is reported as `gitoxide_managed_mutation_replay_required`; projection repair can no longer return `already_current` while a reservation is live.
      - Post-T2 recovery directly reopens the strict operation-bound candidate receipt. It no longer reads the parent content and calls the current transform again.
      - Only the exact `accepted_ref_target_invalid` observation enters parent/candidate repair. Timeout, cancellation, corruption, and unrelated helper failures propagate and fail closed.
      - SQLite exact replay reissues the process-local projection capability before the accepted-ref CAS.
   
   I also corrected the recovery claim: a pure transform is invoked at most once per live Runtime execution, but it may be deterministically recomputed after a pre-T2 process loss. The durable guarantee is **at most one accepted successor**, not exactly-once invocation of a pure function. Once T2/successor is durable, recovery adopts the receipt and does not recompute the transform.
   
   Both branches were rebuilt together from current `upstream/main`; the 14 extracted commits match one-for-one under `git range-diff`. This PR is now the five-commit kernel only, while the nine-commit Gitoxide recovery layer is independently reviewable in the stacked Draft.
   
   <details>
   <summary>中文说明</summary>
   
   感谢这轮审查。我同意 owner 边界的判断,但没有继续机械拆成四个 PR,而是收敛为两个可独立证明、同时又不会过度碎片化的交付:
   
   1. **当前 PR:managed mutation acceptance kernel**
      - Runtime 只拥有一个有界 immutable result 和一个 terminal response event;
      - no-effect capability 绑定签发 owner、具体 execution store 与 durable storage-root identity;
      - SQLite 负责 reservation 仲裁与原子 terminal/successor transaction;
      - managed T1 后继续禁止 generic T2。
   
   2. **第二个 stacked recovery PR:[zhiiw/maka-agent#43](https://github.com/zhiiw/maka-agent/pull/43)**
      - active T1 明确返回 `gitoxide_managed_mutation_replay_required`,projection repair 不会再误报 `already_current`;
      - post-T2 recovery 直接重开严格、operation-bound 的 candidate receipt,不再读取 parent content 并调用当前 transform;
      - 只有精确的 `accepted_ref_target_invalid` 才进入 parent/candidate repair;超时、取消、corruption 与其他 helper 错误原样 fail closed;
      - exact replay SQLite successor 后才重签进程内 projection capability,再执行 accepted-ref CAS。
   
   同时修正了恢复合同:pure transform 在一次 live Runtime execution 中最多调用一次,但 pre-T2 进程退出后可以基于同一 durable operation 做确定性重算。真正的 durable 保证是“最多一个 successor 被接受”,不是“纯函数 exactly once”。T2/successor 一旦持久化,恢复只采用 receipt,不再重算 transform。
   
   两个分支已经一起从最新 `upstream/main` 重建;14 个 extraction commits 在 `range-diff` 中逐一对应。当前 PR 只保留 5 个 kernel commits,9 个 Gitoxide recovery commits 放在第二个 stacked Draft 中独立审查。
   
   </details>


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@maka.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@maka.apache.org
For additional commands, e-mail: commits-help@maka.apache.org


Re: [PR] feat(runtime): establish the managed mutation acceptance kernel [maka]

Posted by "zhiiw (via GitHub)" <gi...@apache.org>.
zhiiw closed pull request #4265: feat(runtime): establish the managed mutation acceptance kernel
URL: https://github.com/apache/maka/pull/4265


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@maka.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@maka.apache.org
For additional commands, e-mail: commits-help@maka.apache.org