Release 1.8.1: make the bundle a straight copy for downstream registries - #38
Merged
Conversation
Review of the vendored copy in K-Dense-AI/scientific-agent-skills#158 surfaced two things that repo had to patch locally after every sync. Both are fixed here so the next sync is a file copy with no local layer. Frontmatter indentation: `metadata` was nested four spaces. That is valid YAML and parses fine with a YAML library, but the registry's validator reads frontmatter line by line and recognizes two-space nesting only, so it reported `metadata.version` as missing and failed the bundle on whitespace. tests/test_structure.py pins it now. Installer commands: the guides handed out `pip install --upgrade idc-index`, which targets whichever interpreter `pip` resolves to and drops the pinned version — the failure scripts/check_version.py exists to prevent, and the reason USAGE.md stopped doing it in 1.8.0. The registry independently rewrites every `pip install` in a vendored skill to `uv pip install`, which is the same class of problem from the other side: any single installer named in the bundle is wrong somewhere. The guides now name the package needed and point at check_version.py, which is the one place that can see the interpreter it is running under — and prefers uv there when uv is on PATH, with `--python` so it targets that interpreter rather than the active environment. Neither form overrides PEP 668. tests/test_check_version.py is new: offline, standard library only, covering version parsing, install-command construction, exit codes, and the guards that the script never shells out to an installer. It runs with nothing installed, which also makes it usable as-is by registries that require a test suite for any skill shipping scripts/. Co-Authored-By: Claude Opus 5 (1M context) <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.
Review of the vendored copy in K-Dense-AI/scientific-agent-skills#158 surfaced two things that registry has to patch locally after every sync. Both are fixed here, so the next sync is a file copy with no local layer.
Frontmatter indentation (blocking downstream CI)
metadatawas nested four spaces. Valid YAML, andmetadata.versionparses fine with a YAML library — but that registry's validator (tests/_contract/structure.py) reads frontmatter line by line and matches^ key:only, so it reportedmetadata.versionas missing and failed the bundle on whitespace. Running their repo-wide contract against a straight copy of 1.8.0 produced exactly one structural failure, this one.Now two spaces, pinned by
tests/test_structure.py::TestFrontmatter::test_metadata_scalars_are_indented_two_spaces.Installer commands
The guides handed out
pip install --upgrade idc-indexin five Prerequisites blocks, pluspip install duckdb/google-cloud-bigquerymentions. A barepip installtargets whichever interpreterpipresolves to and drops the pinned version — the failurescripts/check_version.pyexists to prevent, and whyUSAGE.mdstopped doing it in 1.8.0.The registry independently rewrites every
pip installin a vendored skill touv pip install(their commit4226ca8), which is the same problem from the other side: any single installer named in the bundle is wrong in some environment. So the guides now name the package that is needed and point atcheck_version.pyforidc-index, and that script — the one place that can see the interpreter it is running under — prefersuvwhenuvis onPATH:--pythonmatters: a bareuv pip installtargets the active virtual environment, not necessarily the one that failed to importidc_index. Neither form overrides PEP 668 — both refuse on an externally managed interpreter, which is the intended outcome.tests/test_structure.pyfails on a reintroducedpip/uv/conda/poetryinstall line inSKILL.mdorreferences/.New:
tests/test_check_version.pyOffline, standard library only, 20 tests: version parsing (numeric ordering,
vprefixes, pre-release tags), install-command construction,check_minimum/mainexit codes, best-effort network notices, and guards that the script never shells out to an installer and never bypasses PEP 668. Runs with nothing installed.That last property is deliberate: registries that require a test suite for any skill shipping
scripts/can run this file as-is instead of writing their own. The cases it duplicated were removed fromtests/test_snippets.py, which needsidc-indexinstalled.scripts/**was also missing from thetest-snippets.ymlpath filters, so a change to the bundled script did not trigger CI.Verification
pytest tests/test_structure.py tests/test_check_version.py— 33 passed, no network, noidc-indexSKILL.mdis 495 lines (budget 500)pip/uv/conda/poetryinstall command remains inSKILL.md,references/,USAGE.md, orREADME.mdscripts/check_version.pyrun against a 0.12.3 environment prints both commands and exits 1uv pip install --python <venv> --dry-run 'idc-index==0.12.5'resolves; against an externally managed interpreter it refuses with the PEP 668 message, as intended🤖 Generated with Claude Code