Repository navigation
Guard the released loader protocol against in-place changes - #5
Merged
Merged
Conversation
Every release shares PLUGIN_DATA/runtime-v1/bootstrap.py, and the loader's publish() raises when those bytes differ. A release that edits sol_bootstrap.py and regenerates the pinned hook commands therefore passes the existing pin tests, then fails every installed task with "runtime collision or corruption" and disables all hooks. Freeze the bootstrap digest for the released runtime directory, and show that the same change loads once it moves to a new runtime directory. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
DmitrL-dev
force-pushed
the
fix/bootstrap-protocol-guard
branch
from
September 28, 2026 03:42
e7638ee to
cb2a739
Compare
…l-guard # Conflicts: # plugins/sol-codex/scripts/test_hook_commands.py
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.
Summary
Every SoL Codex release shares
PLUGIN_DATA/runtime-v1/bootstrap.py.sol_bootstrap.pypublishes itself there and raisesruntime collision or corruptionwhen the existing bytes differ. So if a release edits the loader and regenerates the pinned hook commands, all existing pin tests still pass, but every installed task then fails the loader and all hooks degrade silently. The only thing preventing this today is the docstring "Keep this file byte-for-byte".test_released_runtime_directory_keeps_its_bootstrap_bytespins the loader digest for the releasedruntime-v1directory. It also checks that the hook launcher references the same directory and digest, and its failure message explains the fix.test_changed_loader_needs_a_new_runtime_directorychanges the loader after a released loader has run:runtime-v1directory, it reproduces the collision;runtime-v2, the new loader works.Tests only; no runtime change.
Verification
python -m unittest discover -s plugins/sol-codex/scripts -p 'test_hook_commands.py': 13 OK.sol_bootstrap.pyand regeneratedhooks.jsonwithscripts/generate_hook_commands.py. Every existing test still passed; only the new guard failed, with the digest mismatch.🤖 Generated with Claude Code