pyproject: ship the whole dotbot package so data files reach the wheel - #282
Merged
Merged
Conversation
The include list named file types, so dotbot/calibration/app.tcss never reached the wheel and `dotbot run lh2-calibration` crashed for anyone who installed from PyPI; the examples' scene assets were missing too. The leading slash is load-bearing: hatchling patterns are gitignore-style, so a bare `dotbot/` also matches nested directories of that name and sweeps in a local doc/_build tree. AI-assisted: Claude Opus 5
AI-assisted: Claude Opus 5
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## develop #282 +/- ##
===========================================
- Coverage 83.50% 83.50% -0.01%
===========================================
Files 121 121
Lines 11237 11266 +29
Branches 570 569 -1
===========================================
+ Hits 9384 9408 +24
- Misses 1850 1854 +4
- Partials 3 4 +1 🚀 New features to boost your workflow:
|
Contributor
Author
|
Will merge once @nermine11 confirms it works |
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.
Reported from a bench session following the cabled LH2 calibration guide:
dotbot run lh2-calibrationcrashes on a plainpip install pydotbot, andthe workaround was to copy
app.tcssout of the repo intosite-packages/dotbot/calibration/by hand.The cause is the build allowlist, which enumerated file types:
CalibrationAppsetsCSS_PATH = "app.tcss", and nothing in that listmatches
.tcss, so the published wheel contains no stylesheet at all. Thesame gap dropped every
dotbot/examples/asset - the scene.tomlfiles,the PNGs and SVGs - so the labyrinth, charging-station and naming-game
examples are also incomplete for anyone installing from PyPI.
Rather than append
.tcssto the list and wait for the next data file tohit the same trap, this ships the package itself. The leading slash is
load-bearing: hatchling patterns are gitignore-style, so a bare
dotbot/also matches nested directories of that name and pulls in a local
doc/_buildtree.twine checkvalidates metadata, not archive contents, so it never had achance of catching this. The new
utils/check_wheel_contents.pyruns rightafter it in CI and asserts the wheel carries the data files the code opens
by path; extend
REQUIREDwhen another one is added.Not addressed here:
.gitignoreignores*.xml, so the naming-gamemodels/*.xmlare force-added in git and hatchling still excludes them fromthe wheel. That example stays incomplete pending a separate fix.
Validated by building the wheel and inspecting the archive -
app.tcssandthe example assets are present, nothing previously shipped was dropped, and
the check fails as intended when the old include list is restored. Full unit
suite passes (414 tests).