oliver-zehentleitner / maity
hub + cli: make dev and make install share one install recipe (the wheels-only rule in both)
tsk-27fvswf9jzay Proposed
Audit round 4 (tsk-hgnbapyw7hnh), read at 0a1b832e. Kind: design (a rule implemented twice in different ways).
What is wrong
- #2049 added
make devtohub/Makefile(lines 22-26), which installs the locked set with--only-binary :all:because 'a hashed sdist would make pip install its build backend unpinned' (comment at 21).make install(lines 30-32), which CI runs (.github/workflows/ci.yml:283,:304,:479), installs the same two lock files without that flag. So the rule the comment gives holds for developers and not for CI, and the two recipes can drift. - CONTRIBUTING.md now says
make install'installs the same set'; the flags differ. cli/Makefiledev(lines 24-27) installs without--only-binarytoo, and picks its Python with a different expression (PY ?= $(shell [ -x .venv/bin/python ] ...), line 1) than the hub (PYTHON ?= $(if $(wildcard .venv/bin/python),...), hub/Makefile:7).
Proposal
hub/Makefile:devmakes the venv and runs$(MAKE) install PYTHON=$(CURDIR)/.venv/bin/python;installcarries--only-binary :all:(CI then enforces it too, after checking every dev/build pin has a wheel). Do the same incli/Makefile.
Effort / risk: S. Low-medium: a pin without a wheel would fail CI's install; check the locks first.