fix: an update that is not an install, and three provenance fields that were null - #26
Merged
Conversation
…at were null **`software_install` and `software_update` produced byte-identical plans.** Same effects, same artifact, same wording — the only difference was the string in `--operation`. The plan phase may read the local disk and may not reach the network, so what is already under `--prefix` now belongs in it: four situations read as four different plans, and an update of a prefix holding nothing is refused rather than quietly installing, because installing when asked to update is doing something else and calling it done. `software_remove` names the versions it leaves. **Three provenance fields were written empty for every bundle install**, and the bundle carried all three. `component_refs` was an empty list while the conversion report named every component. `setup_stable_id` and `setup_version` were null because `setup-passport.json` — a required member of the format — was required and then discarded, so a target configured over the wire reported no applied setup while the same target configured from the local catalog reported one. `setup_version_passport_digest` stays null on purpose: the passport does not carry its own digest and the contract does not define how one is taken, so a value computed here would be this program's opinion rather than the passport's. **Test fixtures no longer collide between processes.** Nine `scratch()` helpers named a temporary directory after the test alone and each begins by removing it, so two `cargo test` runs on one machine deleted each other's fixtures — measured at six and two failures. They name their process now.
Linux refuses to exec a file any process holds open for writing. The harness runs these in threads and `Command::output` forks: between the fork and the child's exec the child holds a copy of a write handle another thread is about to close, and a thread exec'ing that file in that window is told it is busy. The code under test does not have this shape — `launch` is its own invocation reading a file some earlier one wrote — so the retry is in the two tests that write and exec inside one multi-threaded process.
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.
fix: an update that is not an install, and three provenance fields that were null
software_installandsoftware_updateproduced byte-identical plans. Sameeffects, same artifact, same wording — the only difference was the string in
--operation. The plan phase may read the local disk and may not reach thenetwork, so what is already under
--prefixnow belongs in it: four situationsread as four different plans, and an update of a prefix holding nothing is
refused rather than quietly installing, because installing when asked to update
is doing something else and calling it done.
software_removenames theversions it leaves.
Three provenance fields were written empty for every bundle install, and the
bundle carried all three.
component_refswas an empty list while theconversion report named every component.
setup_stable_idandsetup_versionwere null because
setup-passport.json— a required member of the format — wasrequired and then discarded, so a target configured over the wire reported no
applied setup while the same target configured from the local catalog reported
one.
setup_version_passport_digeststays null on purpose: the passport does notcarry its own digest and the contract does not define how one is taken, so a
value computed here would be this program's opinion rather than the passport's.
Test fixtures no longer collide between processes. Nine
scratch()helpersnamed a temporary directory after the test alone and each begins by removing it,
so two
cargo testruns on one machine deleted each other's fixtures — measuredat six and two failures. They name their process now.
Rendered from
NDDev-it-com/setup-systems@ddab388.https://claude.ai/code/session_011eFMKoUdWcc7Aw9vtMxH2A