You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
1. MEDIUM -- func_registry regenerate-before-bump silently clobbers the shipped version's digest
.agents/skills/mz-commit/SKILL.md:59
The first bullet makes REWRITE=1 cargo test -p mz-compute-types --test func_registry the immediate response to any registry failure, including "removed, or has a changed property"; the bump-first requirement only shows up two bullets later. A rewrite run before the bump overwrites the shipped version's entry in func_registry_digests.json with the new properties' digest, and nothing fails afterwards, so the record of what the shipped LIR version's functions meant is lost.
Details
Mechanism: the REWRITE branch in src/compute-types/tests/func_registry.rs:228 does digests.insert(version, digest(&properties)) keyed on the currentLIR_VERSION, so a pre-bump rewrite replaces "1" rather than adding "2". Bumping afterwards and rewriting again leaves {"1": <new>, "2": <new>}. The checking path only asserts digests.get(&version) for the current version, so the corrupted entry is never revisited. That entry is the only key back into git history for the old version's properties (func_registry.json is rewritten in place, unlike lir_v{N}.json), which is exactly what the digests file exists for.
The test's own failure message orders it the other way round: bump, "so ... version N's digest in ... stays as it is", then regenerate. The LIR section of this same skill gets the ordering right at line 43. .agents/skills/mz-test/SKILL.md:36 inherits the same inverted order.
Fix: put the version decision ahead of the command in bullet 1, e.g. "If the failure names removed or changed functions, settle the LIR_VERSION question below before running REWRITE. A rewrite at the old version overwrites that version's digest entry instead of adding a new one, and no later check catches it."
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
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.
Motivation
Teach skills about the new registries.
#38868
#37814
Description
New registries place new demands on the code we build; we need to have the various agents know about them.
Verification
haha 😅