Skip to content

CI: fix nightly vlt migration tests for eject (#1774) - #1775

Merged
Mikola Lysenko (mikolalysenko) merged 3 commits into
mainfrom
agent/fix-ci-vlt-migration-eject
Oct 28, 2026
Merged

Mikola Lysenko (mikolalysenko) merged 3 commits into
mainfrom
agent/fix-ci-vlt-migration-eject

Conversation

@mikolalysenko

@mikolalysenko Mikola Lysenko (mikolalysenko) commented Oct 28, 2026 •

Copy link
Copy Markdown
Collaborator

LLM Description written by Claude Code:claude-opus-5-5

Fixes #1774

Summary

Every e2e-extended (mode_migration_vlt, *) leg has been red on the nightly since #1648 (run 40639505834): vlt_pinned_matrix_migration_dry_run_parity and vlt_pinned_matrix_migration_hosted_then_vendored fail on vlt 0.0.0-32, 1.0.0-rc.14 and 1.2.0 (Linux, and the Windows/macOS legs).

Root cause

#1648 made plain vendor with a hosted pin in scope an eject: the dry run reports eject_planned (not vendor_would_revert_redirect), and the wet run no longer emits vendor_takeover_reverted_redirect. #1648 updated the PR-tier migration suites (mode_migration_bun.rs, _npm, _cargo, _pypi) and the in-process vlt test (in_process_vendor_bun_takeover/vlt.rs), but missed mode_migration_vlt.rs. Its tests are #[ignore] (real vlt) and run only in the nightly, so PR and merge-queue CI never saw it. The vendor runs themselves succeed; only the stale advisory assertions fail.

Same #1648 fallout as #1770 (e2e_bun_lockb.rs, fixed in #1771 / #1772); a different file, so no overlap.

Changes (test-only, crates/socket-patch-cli/tests/mode_migration_vlt.rs)

  • New helper assert_vendored_over_hosted(eject, ..): only the scan --mode vendored takeover may announce vendor_takeover_reverted_redirect; the plain vendor eject must not. Both must report no redirect_revert_failed and the redirect_vlt_reinstall_required warning from the warm-store heal (the contract in_process_vendor_bun_takeover/vlt.rs asserts).
  • hosted_then_vendored, vendor driver: the staged manifest must be byte-identical after the eject.
  • dry_run_parity: vendor --dry-run must plan exactly one eject (eject_planned), for the hosted pin and not the bystander, and must not emit vendor_would_revert_redirect; the wet vendor uses the helper.
  • Doc comments say eject, not takeover, for plain vendor.

Everything after the vendor runs (pure vendored lock, fresh-checkout installs, exact vendor --revert, hosted re-scan) is unchanged.

Evidence

Run locally with the real vlt releases the nightly pins (scripts/install-vlt.sh, SOCKET_PATCH_VLT_E2E_{JS,VERSION,REQUIRED}, LANG=C), cargo test -p socket-patch-cli --all-features --test mode_migration_vlt -- --include-ignored vlt_pinned_matrix:

vlt origin/main this branch
1.2.0 FAILED 12 passed / 2 failed (panics at :312 and :360, same as nightly) ok, 14 passed
0.0.0-32 (nightly red) ok, 14 passed
1.0.0-rc.14 + upgrade 1.2.0 (nightly red) ok, 14 passed

Also: cargo fmt --all -- --check clean; cargo clippy --locked -p socket-patch-cli --all-features --test mode_migration_vlt -- -D warnings reports the same 2 pre-existing duplicate_mod errors as main and nothing new. (The sandbox's TLS proxy is not in reqwest's webpki roots, so I pre-seeded the harness's npm package cache with curl; the test code is unchanged by that.)

Windows/macOS legs are not run on PRs; the change is platform-neutral (no cfg), so no full-scope dispatch.

/code-review high

Fixed: eject tied to the hosted purl with an exact count; manifest-untouched check on the eject; heal warning asserted for both drivers (verified the scan takeover emits it on all three vlt releases); bool instead of a driver-name string; stale doc wording and wrapping.

Not fixed:

  • Staging a different patch in the manifest (as the PR-tier bun/yarn suites do) would need a second hosted record and artifact in this real-vlt fixture. The PR-tier in_process_vendor_bun_takeover/vlt.rs already covers "the manifest is not the eject's input"; this nightly leg now checks the manifest is untouched.
  • The empty "Start fix" commit is the claim marker; the PR is squash-merged.

CI cost

No workflow change. Lean PR run: same ~28 Linux jobs, ~8 min, before and after. These legs stay nightly-only.

https://claude.ai/code/session_011f9aePnKQscLjaCGykq81B


Generated by Claude Code

Assisted-by: Claude Code:claude-opus-5-5
The nightly mode_migration_vlt legs have failed on every vlt release
since #1648. That change made plain `vendor` with a hosted pin in
scope an eject: the dry run reports `eject_planned`, and the wet run
no longer announces a per-purl takeover. The PR-tier migration suites
were updated, but these real-vlt tests run only nightly and still
expected the old takeover advisories.

Assert the eject contract instead: `eject_planned` on the dry run, and
on the wet `vendor` no takeover event, no revert failure, and the
`redirect_vlt_reinstall_required` warning from the store heal.
`scan --mode vendored` keeps asserting its takeover. The vendor runs
and every later check (pure vendored lock, fresh checkouts, exact
revert) are unchanged.

Fixes #1774

Assisted-by: Claude Code:claude-opus-5-5
Tie the dry run's `eject_planned` to the hosted pin (exactly one plan,
not the bystander), check that the eject leaves the staged manifest
byte-identical, and require the warm vlt store heal warning from both
the scan takeover and the eject. Pick the driver's contract with a
bool instead of a driver-name string, and fix stale doc wording.

Refs #1774

Assisted-by: Claude Code:claude-opus-5-5
@mikolalysenko
Mikola Lysenko (mikolalysenko) marked this pull request as ready for review October 28, 2026 08:08
@mikolalysenko Mikola Lysenko (mikolalysenko) added the ci-janitor Opened by the CI janitor routine (flakes, redundant tests, CI perf) label Oct 28, 2026
@mikolalysenko

Copy link
Copy Markdown
Collaborator Author

BugBot review


Generated by Claude Code

@cursor cursor Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

✅ Bugbot reviewed your changes and found no new issues!

Comment @cursor review or bugbot run to trigger another review on this PR

Reviewed by Cursor Bugbot for commit ccb4d43. Configure here.

@mikolalysenko Mikola Lysenko (mikolalysenko) added the Ready for review Agent-verified: mergeable, CI green, Bugbot clean — awaiting human review label Oct 28, 2026
@mikolalysenko

Copy link
Copy Markdown
Collaborator Author

Ready for review at ccb4d431 (burn-down agent).

  • CI: 32 success + 50 skipped on this head, 0 failing; mergeable into main.
  • Bugbot: reviewed ccb4d43, no findings, 0 open threads.
  • Reviewer note: test-only change to mode_migration_vlt.rs; those legs are nightly-only, so the nightly run after merge is the real confirmation.
  • Slack announcement not sent this run (Slack send tool unavailable to the agent).

Generated by Claude Code

@mikolalysenko

Copy link
Copy Markdown
Collaborator Author

Ready for review at ccb4d431 (burn-down agent).

  • CI: 82/82 check runs green or skipped (32 success, 50 skipped); mergeable, no conflicts.
  • Bugbot: reviewed ccb4d431, no findings; no unresolved review threads.
  • Test-only change to the nightly mode_migration_vlt tests; the nightly legs confirm after merge.

Generated by Claude Code

@mikolalysenko

Copy link
Copy Markdown
Collaborator Author

Final review brief

What it does. Test-only fix for the nightly mode_migration_vlt legs (all vlt versions, all OSes), red since #1648 made plain vendor over a hosted pin an eject. The suite still asserted the old takeover advisories; it now expects eject_planned in the dry run and no takeover event from the wet vendor, while scan --mode vendored still must announce its takeover.

Risk: low. One test file; no product code. These tests are #[ignore] (real vlt) and run only nightly, so PR CI doesn't exercise them.

Look here

Verified

  • Read the full diff. Asserted codes exist where expected (commands/vendor.rs:1940 eject_planned, vlt_heal.rs:35 redirect_vlt_reinstall_required) and match the in-process contract in in_process_vendor_bun_takeover/vlt.rs.
  • cargo clippy -p socket-patch-cli --all-features --test mode_migration_vlt -- -D warnings: only the pre-existing duplicate_mod error (same on main), nothing new. I did not re-run the real-vlt legs here (needs the pinned vlt releases); the PR body shows them red on main and green on this branch for vlt 1.2.0, 0.0.0-32 and 1.0.0-rc.14.
  • CI 32 passed / 50 skipped of 82 on the head; ci-ok green. Cursor Bugbot: passed. CHANGELOG.md untouched. No overlap with CI: update bun.lockb offline takeover test (#1770) #1771 (different file).

Changes I made: none. (Nit, not blocking: two re-flowed doc-comment lines at the top of the file and in the dry-run-parity doc run past 100 columns; rustfmt doesn't wrap comments, so CI is fine.)

Open questions: none.

Auto-merge (squash) is armed, so approving sends it straight to the merge queue.


Generated by Claude Code

Merged via the queue into main with commit eb094a5 Oct 28, 2026
82 checks passed
@mikolalysenko
Mikola Lysenko (mikolalysenko) deleted the agent/fix-ci-vlt-migration-eject branch October 28, 2026 14:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ci-janitor Opened by the CI janitor routine (flakes, redundant tests, CI perf) Ready for review Agent-verified: mergeable, CI green, Bugbot clean — awaiting human review

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Nightly mode_migration_vlt red: vendor tests predate #1648 eject

4 participants