Skip to content

Capture cadence test writeback from the fixture workspace - #9726

Open
cocolord wants to merge 1 commit into
loopx-project:mainfrom
cocolord:codex/cadence-workspace-fixture-20261201
Open

cocolord wants to merge 1 commit into
loopx-project:mainfrom
cocolord:codex/cadence-workspace-fixture-20261201

Conversation

@cocolord

@cocolord cocolord commented Dec 1, 2026

Copy link
Copy Markdown
Member

Why

The settled-turn cadence test records writeback against a synthetic Goal workspace. Its refresh-state call ran from the source checkout, so automatic workspace capture could inspect the source clone's Git identity and reject a valid fixture writeback. This reproduced in two parameter cases in an isolated Linux clone.

Run that call from the fixture project, as the adjacent writeback tests do. This exercises automatic capture at the repository that owns the fixture evidence.

Validation

  • All eight settled-turn cadence parameters passed on this revision.
  • Both reproduced cases passed in the same 189-case Linux workload after applying the fixture change.
  • Ruff and standard premerge passed. The premerge ran five direct checks and three canaries.

@loopx-agent loopx-agent left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reviewer: model_agent · gpt-6.2-sol · OpenAI · runtime_reported · xhigh

动机 / Motivation

维护已结算 Turn cadence 的贡献者需要用实际 CLI 检查回执何时计入周期。 前一版的循环用仓库源码 checkout 当 cwd 写回。启用已登记的只读核验合同时,原 owner 会将不同的仓库身份拒绝。 候选只将循环的 refresh-state cwd 指向当前合成 Goal 的 fixture project,自动捕获走实际产生证据的目录。 本次改动只涉及一个现有测试调用点。

改动思路 / Approach

用夹具目录启动原 CLI。这样生产逻辑会自行捕获实际交付目录。一次参数传递即可修正定位,同时保留原先在写回后、扣额前和扣额后的 cadence 断言。

具体改动 / Changes

评审提交 8a5d64b,基线 2d47ab9,一个测试文件新增一行。实际交付工作区 仍遵循冻结的 Turn 协议与 refresh-state 校验。相同注册表、运行目录和 Turn identity 通过原 helper 参数传入。仅更新每个周期写回的 cwd,保留写回后暂不推进、receipt 缺失时不计入以及结算后的原周期阈值。正例使用现有 fixture 解析而非预填 workspace receipt。 规范 · 捕获校验 · 测试位置

对主干的风险 / Risks

在两个精确头上用已声明的只读 verify fixture 执行同一个两轮 cadence 用例,基线首轮从源码 checkout 退出 1,候选两轮从 fixture project 写回成功且原 cadence 结论成立。 独立真实 CLI 在基线和候选均拒绝外部 Git cwd,不新增扣额。切回注册 fixture 后原 Turn 可写回,重放两次 spend 只有一笔。 候选模块 31 项通过,标准 premerge 的 5 项直接检查及 3 项选中检查全通过。 同作者 #9724 修改 Chat 和 Steward 测试,两份改动没有共同 helper 或可消除的重复用例。

我的整体评价 / Verdict

APPROVE。 复验确认测试已经从正确工作区调用,原有项目归属和结算边界得到保留。本地 macOS 上基线原样的 8 个参数也通过。独立复现用同一测试增加了显式只读声明,作者环境的 Linux 并发套件没有重跑。

English verdict: APPROVE at 8a5d64b. The registered fixture passes the original cadence assertions and the foreign Git workspace remains refused. Replaying the same debit records it once.

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants