Repository navigation
fix(workspace): upgrade report excludes .venv/docs from the ADDED walk (#951) - #952
Merged
Merged
Conversation
The #949 fix switched the preview/report classifier to `find -L` so it follows the Nix image's store-symlink template. But `find -L` also descends the baked .venv symlink tree, so the ADDED section over-reported phantom .venv/.../site-packages/* files the real rsync copy never writes. Mirror the static excludes the real copy applies (.git, .venv, docs/issues/, docs/pull-requests/) in the report `find` so ADDED matches what the upgrade actually does. Refs: #951
c-vigo
enabled auto-merge
July 9, 2026 08:54
Contributor
Author
|
Reviewed: single-site change adding |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
--preview/--forceupgrade report over-reported ~1763 phantom.venv/…/site-packages/*files in the ADDED section that the real upgrade never writes, making the ADDED list unusable. Report-only bug — no data risk.Root cause
The #949 fix switched the report classifier to
find -L(assets/init-workspace.sh:534) so it follows the Nix image's store-symlink template — correct for the OVERWRITTEN section. Butfind -Lnow also follows the baked template's.venvsymlink tree. The reportfindexcluded only.git, whereas the real rsync copy excludes more:So every symlinked
.venvfile leaked into ADDED.Fix
Mirror the copy's static excludes in the report
find(single-site change, line 534):.venvis the one that leaks today; the twodocs/*excludes are for parity so future template changes can't leak either.Test evidence (TDD)
New bats test
upgrade preview omits the baked .venv symlink tree from ADDED (#951)places a symlinked.venv/…/site-packages/phantom-venv-pkg.py(mirroring the image's baked venv) plus a normal symlinked template file underTEMPLATE_DIR, and asserts the normal file is still in ADDED while the.venvfile is not.refute_output --partial "phantom-venv-pkg.py"failed — the.venvfile showed in ADDED.init-workspace.batssuite 124/124 green.Full
prek run --all-fileshook suite green (sync-manifest mirror ofCHANGELOG.mdre-staged).Refs: #951
Closes #951