Repository navigation
Live checks for preflight-upgrade, and a refusal that changes nothing - #11
Merged
Merged
Conversation
The first upgrade live checks ran from a scratch folder that no longer exists, so they couldn't be rerun. test/live/upgrade.mjs runs the real CLI jar against a made-up server booted by real Paper, in a temp folder deleted on exit: an all-clear check, broken plugins along a required-by chain, a never-off rule, every refusal in docs/upgrade.md, apply, status, restore, the JSON shape and exit codes, and linked worlds left unchanged. Four test-only fixture plugins and a session.lock holder are built from source in the repo. 94/95 on 26.1.2 and on 26.1.2 checked against 26.3. The one failure is left failing on purpose: when apply refuses because a world is open, it has already created plugins/Preflight/upgrade/.lock, though the docs say nothing changes. Not run on 26.2. Paperclip fetches the official Mojang jar on each boot. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
apply and restore took their own lock, which creates plugins/Preflight/ upgrade/.lock, before checking the server was stopped. So a refusal left files behind, though docs/upgrade.md promises nothing changes. They now check first, and again once locked. Found by the new live checks, which are now 95/95 on a 26.1.2 server checked against 26.3. The unit test fails without the fix. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
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.
K350: the upgrade CLI's live checks are back in the repo. The originals ran from a scratch folder that's gone.
test/live/upgrade.mjsruns the real CLI jar against a made-up server folder that a real Paper jar booted, in a temp folder that's deleted when the run ends, pass or fail. Four test-only fixture plugins fail in different ways.It covers:
The live checks found one bug, fixed here.
applyandrestorecreatedplugins/Preflight/upgrade/.lockbefore refusing a running server, though the docs promise nothing changes. They now check first, and again once locked.Tested: 95/95 on a 26.1.2 server checked against 26.3 (94/95 on 26.1.2 and on 26.3 before the fix). Unit tests 31/31; the new assertion fails without the fix.
Not tested: 26.2; outward-plugin "not checked";
--copy,--exclude,--work-dir, a hung copy, and a rename failing part-way. Unit tests cover most of those; docs/test-audit.md says which.🤖 Generated with Claude Code