Repository navigation
test(update): derive pip and pipx activation fixtures from their real owner - #7675
Conversation
Signed-off-by: LoopX Agent <337587101+loopx-agent@users.noreply.github.com>
Signed-off-by: LoopX Agent <337587101+loopx-agent@users.noreply.github.com>
交接:Windows 上验证过这个修复这个 PR 修的正是 根因是那 4 个用例用共享的 doctor fixture 描述 release snapshot 属主,而 Windows 上 本 PR 自己的 Windows run 未能证明这一点:它的 所以这里附上一个等价的修复在 Windows runner 上跑完的实测结果: 零失败,其中包含这 4 个 self-update 用例。同一份改动在 macOS 上是 本 PR 的做法与这份实测一致(同样是按 driver 派生的属主 doctor report),并且额外 |
这个 PR 的 run 正占死全仓库的 6 条 test-shard lane排查 #7695 的 CI 时发现:仓库里所有 PR 的 外加 main 的 run 这 7 个 job 的日志都在 01:47 左右同时停止输出(runner 失联),而 job 自身的 解除办法(需要上游 admin 权限,我这边是 403)取消这两个 run 会释放全部 6 条 lane,本 PR 和仓库里其他 PR 的 shard 就能开始跑。 这不是本 PR 的改动造成的:本 PR 只改 顺带一提:本 PR 的修复本身有 Windows 实证本 PR 修的正是 |
更新:占死 6 条 lane 的 7 个 shard 里,有一个是本 PR 的上一条评论说占死 lane 的是本 PR 的 run 加上 main 的 run。重新全量扫描(这次覆盖了 也就是说,除本 PR 的 run 之外,#7695 的 run 也有一个 shard 卡在同一分钟。 这些 job 不是测试卡住,而是 runner 中途失联:
runner 断开后 job 永远停在 解除办法(需要上游 admin;fork 身份是 403)取消后需要给这两个 PR 重新触发一次 CI。#7695 的另外 5 个 shard 一旦有 lane 就会 这不是本 PR 的改动造成的:本 PR 只改 |
Goal And Delivered Outcome
Four Windows activation tests start with an archive-snapshot plan and then overwrite only
execution_driverwith pip/pipx. Windows correctly refuses the original archive plan, leavingplan.apply_supported=false, so these tests stop before exercising their intended package-manager path. This failure is visible in the Windows job on #7630.Build each fixture through the real installation-owner planner: Python-distribution metadata selects pip/pipx, while the archive arm retains source-snapshot planning. Both test families now share this setup and assert planner admission and the selected driver before mocked execution. Their route propagation, launcher ownership and failure assertions remain.
Author Declaration
loopx/self_update.pyat8caaf678e52019453ca3e5a2adf363c954ae2642; no separate written specification. Intended base:main.apply_plan_for_driver; both existing parametrized test familiesScope And Continuation
Complete within the fixture repair. One test file changes; updater behavior, platform admission and service activation are untouched. This is independently reviewable from #7630. Its merge does not certify that PR's remaining checks, performance or adoption.
Validation
The current head incorporates
main; the proposed test file is byte-identical to the original repair. The earlier Windows run stopped before activation tests at a CLI output-budget failure on its older base (job). That failure is retained; it did not qualify the Windows fixture repair.36cdca826383c7adaacc0c9441d05bedb5369b38; base99cfa3ac559bfa237f04f36fb7e926672fea44b2.uv run --extra test python -m pytest -q tests/test_self_update_runtime_activation.py tests/test_python_install_owner_platform.py: 58 passed, 6 platform-specific skips on macOScqr_617a9ec57899953a6e60verified: zero blockers, one native-Windows validation warningtodos/todos_exacttimeouts; the Windows workflow and all required CI are not qualifiedNo real installer, package upgrade or service restart was executed. No UI changes; visual evidence is not applicable. No shared protocol/vocabulary, RFC pair or runtime/backend surface changes.
Boundary Checklist