build: use uv_build backend for publishable packages and re-enable --require-hashes#1019
Draft
MvLieshout wants to merge 1 commit into
Draft
build: use uv_build backend for publishable packages and re-enable --require-hashes#1019MvLieshout wants to merge 1 commit into
MvLieshout wants to merge 1 commit into
Conversation
…require-hashes Signed-off-by: Marnix van Lieshout <marnix.van.lieshout@alliander.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.



What
openstef-core,openstef-models,openstef-beam,openstef-foundation-models,openstef-meta) from thehatchlingbuild backend to uv's nativeuv_build.--require-hasheson those package builds in thebuildpoe task (reverted in fix: revert require hashes. #1009).Why
uv build --require-hasheswas reverted in #1009 because it cannot be satisfied withhatchling: hatchling builds in an isolated PEP 517 environment whose build dependencies are not inuv.lockand cannot be hash-pinned, so uv has no hashes to verify.uv_buildis built into uv and performs an in-process direct build — no isolated environment and no third-party build backend to resolve/install/hash — so hashed builds pass. Verified locally: all five packages build underuv build --package <pkg> --require-hashes.Notes
src/<module>) with the module name matching the normalized project name, which is exactly uv_build's default, so their[tool.hatch]build.targets.wheel.packagesblocks are dropped with no replacement config needed.requires = ["uv_build<0.12"]is an upper bound only (no lower bound to maintain); uv recommends an upper bound so the published sdist stays buildable when a future breakinguv_buildships.openstefmeta-package stays onhatchling: it ships no module (only dependencies), and uv_build requires a module. It is built without--require-hashes— it contains only metadata, no code.openstef-deployment-examplesremains excluded from the publishable set.uv.lockis unchanged (build backends are not locked dependencies).