Skip to content

test(workspace): read visible unassigned Task metadata - #5641

Merged
huangruiteng merged 1 commit into
mainfrom
codex/workspace-owner-browser-20261005
Oct 5, 2026
Merged

huangruiteng merged 1 commit into
mainfrom
codex/workspace-owner-browser-20261005

Conversation

@loopx-agent

Copy link
Copy Markdown
Collaborator

Packaged workspace acceptance times out while an unclaimed Task already displays “未分配”. The exact-text locator assumes that the owner has a separate element; the current card renders it as a text node beside status badges. Read the visible metadata instead and keep the inspector's exact owner check.

This repairs the common typed-actions scenario used by the frontstage, packaged workspace and dashboard acceptance lanes. The current main bundle remains unchanged. Ownership still comes from the canonical claim; no assignment, permission or runtime behavior changes.

Validation: clean main fae7fd5e9 reproduces the original 30-second timeout with the label visible. The same packaged bundle passes the complete scenario with this change (50 seconds). The source-schema/renderer ownership smoke passes, and isolated visible-metadata mutations that replace or remove the unassigned label are rejected. Node syntax and diff checks pass. These are offline packaged/fixture checks; they do not qualify a live collaboration episode or other CI failures.

Related boundary: the L1 inspection work in #5587 wraps the owner in an element, but the common acceptance should also work with current main's existing rendering. This small test repair can be reviewed independently. The future-facing pass keeps the existing metadata and inspector assertions together without adding a helper or changing presentation.

中文:未认领任务已正确显示“未分配”,浏览器验收却因要求独立 DOM 元素而超时。本次改为检查卡片的可见元数据,并保留详情中的准确 owner 校验。同一打包页面从原断言超时变为整个场景通过;未分配标签缺失或被实际负责人替代时,断言仍会失败。只修复验收定位,不修改产品、权限或任务归属规则,也不认证真实模型协作。

Signed-off-by: LoopX Agent <337587101+loopx-agent@users.noreply.github.com>

@loopx-agent loopx-agent left a comment

Copy link
Copy Markdown
Collaborator Author

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.1-sol; OpenAI; runtime_reported; reasoning_effort=xhigh

Approval conclusion (author-owned PR; GitHub blocks formal self-approval)

Exact head: 74f4315c6f6edaf8e17de913e74e22f0d6a45b5c. No blocking finding.

动机

运行个人工作区浏览器回归测试、核验未领取任务归属的维护者。卡片已显示“待执行 未分配”,旧测试却要求“未分配”有独立元素而找不到;新测试读取可见 metadata,并保留详情页 Owner 的精确检查。真实打包页面里旧精确元素匹配数为零,新断言和详情 Owner 通过;删除或替换标签均使新断言失败,刷新恢复通过,fixture durable writes 为零。本 PR 仅修复已有测试,未修改生产归属规则,也不证明真实 authority 后端、模型或整套浏览器流程。

改动思路

沿用现有公共浏览器 smoke,只修正读取事实的方法。fixture 的 Current Todo 没有 claim,即使项目 owner 和 Agent current_todo 提到 example-agent,也不能据此指派任务。卡片当前把状态放在 span、把未分配放在相邻文本节点;把生产 DOM 改成适应测试的结构没有必要。新检查限定在这张卡片的直接按钮 metadata,详情 Owner 的精确检查保持。

具体改动

整个 PR 只有 examples/personal-workspace-browser/typed-actions.mjs,+5/-1:引入 node:assert/strict,以 assert.match 检查可见整行文本,补两行原因注释;点击任务、详情 Owner、关闭详情及后续公共流程不变。accepted specification 为 AGENTS.md,revision fae7fd5;Smoke Retention Policy 在此 head implemented:守护已上线归属事实,复用已有场景而不新增一次性 smoke。

本轮实际重新构建并校验 Chat bundle,独立 Chromium 页面观察 1200px 完整视口,卡片呈现待执行/未分配、无水平溢出;进入详情 Owner 精确为未分配,关闭再刷新仍正确。产品输入与基线一致,PR 没有生产改动。source syntax、diff check 与 npm run smoke:todo-ownership 均通过,后者覆盖不存在/null/实际 claim、历史和 stale display label。

对主干的风险

最强风险是改断言后只让测试变绿、丢掉归属检查。已执行两个相反案例:把可见未分配换成 example-agent,以及删除该文本,新 assert.match 均失败,恢复并刷新后通过;fixture durableWriteCount=0。旧卡片内精确独立元素匹配数为零,但可见文本存在,支持此次修复原因。公共 SSR/schema smoke 与本次浏览器路径互补,相关 PR5587 的编辑/证据流程不重复此修复。

真实页面使用仓库 synthetic HTTP 数据,不代表 live authority、模型或长期运行。本轮独立执行变更区块、卡片/详情、负例和恢复;作者声明整套公共 Playwright runner 通过,本轮未独立重跑其余未改的长流程。私有 HTTP adapter 的初始适配错误与缺失 tsx 调用已纠正,均未修改预期或生产源码。

我的整体评价

APPROVE。long_horizon preserved:生产状态、claim 和调度没有改动,现有 smoke 不再被无效 DOM 形状要求提前阻断;user_experience preserved:用户操作不变,维护者核验成本预期下降,未量化时间收益。小型未来维护整理已落实为复用公共场景、删除偶然元素约束;不添加并行 runner 或兼容层。这是完成已有测试修复,不是完整个人工作区或长期 Goal 验收。

English verdict: APPROVE - 74f4315; scoped visible-metadata assertion repairs a false DOM-shape failure while exact detail ownership stays guarded. Packaged Chromium critical path, two negative DOM mutations, restored reload, canonical ownership smoke, syntax and diff checks passed. Full unchanged Playwright runner and live authority/model were not independently executed.

@huangruiteng
huangruiteng merged commit 2856f22 into main Oct 5, 2026
19 of 25 checks passed
@huangruiteng
huangruiteng deleted the codex/workspace-owner-browser-20261005 branch October 5, 2026 04:44
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