Skip to content

Count shared-data and shared-scripts as wheel file selection - #2466

Closed
Cherith1222 wants to merge 1 commit into
pypa:masterfrom
Cherith1222:fix/1973-shared-scripts-selection
Closed

Cherith1222 wants to merge 1 commit into
pypa:masterfrom
Cherith1222:fix/1973-shared-scripts-selection

Conversation

@Cherith1222

@Cherith1222 Cherith1222 commented Oct 7, 2026 •

Copy link
Copy Markdown

Summary

A wheel target that set only shared-scripts or shared-data was treated as having no file selection, and the build raised "Unable to determine which files to ship". force-include already counts as selection. shared-scripts and shared-data now do too.

Fixes #1973.

The unreleased hatchling history note is in docs/history/hatchling.md. Closed pull request #2262 touched the same issue and was not merged; this branch does not copy that diff. The maintainer there asked for a shorter comment and for issue numbers to stay out of the tests.

Test Plan

On Windows, Python 3.13:

  • pytest tests/backend/builders/test_wheel.py -k considered_selection → before the change, 2 failed and 3 passed; after, tests/backend/builders/test_wheel.py was 109 passed and 7 skipped.

Not run: the rest of the hatch tests, hatch fmt --check, ruff, mypy, other Python versions, and non-Windows.

AI assistance

Drafted with Cursor. The account owner authorized opening this pull request. A human has not reviewed the diff. There is no Co-authored-by, Reviewed-by, or Signed-off-by trailer.

A wheel target that only defines shared-data or shared-scripts no longer raises the 'Unable to determine which files to ship' error, matching force-include.

AI-assisted (Cursor); not yet reviewed by a human.
@cjames23

cjames23 commented Oct 9, 2026

Copy link
Copy Markdown
Member

https://hatch.pypa.io/latest/community/contributing/#ai-contributions - There needs to be a human in the loop. The description already indicates this policy is violated

@cjames23 cjames23 closed this Oct 9, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

shared-scripts cannot be used with empty include

2 participants