fix: anchor lib/ and lib64/ patterns to repo root in .gitignore#3083
Merged
mnriem merged 1 commit intoJun 22, 2026
Merged
Conversation
The unanchored `lib/` pattern matched any nested `lib/` directory, including `src/specify_cli/bundler/lib/` added in github#3070. Hatchling uses .gitignore as its file-exclusion filter, so the bundler subpackage was silently dropped from wheels built via `uvx --from git+...`, causing: ModuleNotFoundError: No module named 'specify_cli.bundler.lib' Prefixing with `/` anchors both patterns to the repository root, which is the intended scope (exclude top-level lib/ artefacts from old-style setuptools installs) without affecting nested source packages.
Collaborator
|
Thank you! |
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
specify bundlecommands fail with aModuleNotFoundErrorwhen the package is installed directly from git (e.g.uvx --from git+https://github.com/github/spec-kit.git):Root cause
.gitignorecontains an unanchoredlib/pattern (line 13) inherited from the GitHub Python gitignore template added in the initial commit. Hatchling uses.gitignoreas its file-exclusion filter when building wheels. The unanchored pattern matches anylib/directory at any depth, includingsrc/specify_cli/bundler/lib/which was introduced in #3070. As a result the entire subpackage is silently dropped from the built wheel.Fix
Prefix both
lib/andlib64/with/to anchor them to the repository root:A leading
/in.gitignoreanchors the pattern to the root of the repository, which is the intended scope — excluding top-levellib/artefacts produced by old-style setuptools installs — without affecting any nested source package namedlib/.Verification
bundler/libis now present in the wheel. Before this fix it was absent.