Skip to content

Conversation

@chrisburr
Copy link
Member

Summary

  • Each sub-package (diracx-api/, diracx-core/, etc.) was missing the LICENSE file in published sdists and wheels because hatchling only auto-discovers license files in the package's own directory, not the monorepo root
  • Added [tool.hatch.build.targets.sdist.force-include] to all 8 sub-package pyproject.toml files to pull the root LICENSE into each sdist
  • The wheel (built from the sdist) then auto-discovers the LICENSE and places it in .dist-info/licenses/

@read-the-docs-community
Copy link

read-the-docs-community bot commented Feb 9, 2026

Documentation build overview

📚 diracx | 🛠️ Build #31332045 | 📁 Comparing 9250a74 against latest (4fad58f)


🔍 Preview build

No files changed.

Use hatchling's force-include to pull the root LICENSE into each
sub-package's sdist. The wheel built from the sdist then auto-discovers
the LICENSE and places it in .dist-info/licenses/.
@aldbr aldbr force-pushed the fix/include-license-in-subpackages branch from 0554d3a to 9250a74 Compare February 9, 2026 12:53
Copy link
Contributor

@aldbr aldbr left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Don't you need the same change for the wheel for completeness?

https://hatch.pypa.io/1.9/config/build/#forced-inclusion

@chrisburr
Copy link
Member Author

It isn't needed as it's auto-discovered from the sdist while building the wheel.

@aldbr aldbr merged commit 9073611 into DIRACGrid:main Feb 9, 2026
29 checks passed
@chrisburr chrisburr deleted the fix/include-license-in-subpackages branch February 9, 2026 18:51
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.

2 participants