You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Trim the minimal wheel's declared dependencies to the export-only set
The opt-in minimal wheel build (`EXECUTORCH_BUILD_MINIMAL=1`) previously trimmed the packaged files but not the declared dependencies. Because `pyproject.toml` `[project.dependencies]` is static, a normal `pip install` of the minimal wheel still pulled `coremltools`, `scikit-learn`, `pandas`, `hydra-core`, `omegaconf` and the test-only deps (`expecttest`, `hypothesis`, `kgb`, `parameterized`), which is most of the real install size. The CI smoke test only passed because it used `pip install --no-deps`.
Make `dependencies` dynamic in `pyproject.toml` and compute `install_requires` in `setup.py` per build mode. The full wheel keeps the existing set unchanged; the minimal wheel declares the subset of that set which `executorch.exir` needs to export a `.pte`: `flatbuffers`, `numpy`, `packaging`, `pyyaml`, `ruamel.yaml`, `sympy`, `tabulate`, `typing-extensions`. `torch` stays consumer-provided and `mpmath` comes transitively via `sympy`. The minimal set is derived from the full set so version pins and markers cannot drift.
Also make the minimal build skip the non-minimal cmake targets explicitly, drop `--no-deps` from the smoke test so dependency resolution is exercised, and assert the built wheel METADATA declares exactly the slim set and none of the heavy deps. Document the slim dependency set in `README-wheel.md`.
Co-authored-by: Jacob Szwejbka <20804483+JacobSzwejbka@users.noreply.github.com>
0 commit comments