[GH-ISSUE #214] setup.py: a tagged checkout installs the newest engine, Hugging Face main files and unpinned Python packages #114

Closed
opened 2026-11-04 01:40:04 +07:00 by bsakaguchi · 4 comments
Owner

Originally created by @alphastorm on GitHub (Sep 30, 2026).
Original GitHub issue: https://github.com/Niko1221/Strata/issues/214

Setup run from a v0.1.27 checkout does not install a fixed v0.1.27 stack. It fetches:

  • the engine from releases/latest (setup.py#L56), i.e. whichever release is newest when setup runs;
  • the model shards and mmproj from each Hugging Face repo's main (#L49, #L83-L100), and the MTP tensors from Qwen/Qwen3.8-Flash-Next at main (tools/mtp_fetch.py#L22);
  • numpy, jinja2, regex, pyyaml, tqdm, requests, cmake, ninja, pillow, psutil without versions (setup.py#L62).

So the same checkout can install different components from one day to the next, and once a newer release is out, an older checkout's serve/ runs against a newer engine than the one it shipped with.

We needed a reproducible install, so we passed --prebuilt <local folder> and --gguf-dir with files fetched at fixed revisions, and pointed tools/mtp_fetch.py's REPO at a fixed revision, since there is no option for it.

Suggestions:

  • default --prebuilt to the release that matches the checkout (releases/download/v<version>/, with the version source_version() already reads from CMakeLists.txt), falling back to releases/latest when that release does not exist;
  • pin each Hugging Face URL to a commit (resolve/<commit>/) in the model table and in mtp_fetch.py, or accept one as an option;
  • pin the Python packages (a requirements file with versions, optionally hashes).
Originally created by @alphastorm on GitHub (Sep 30, 2026). Original GitHub issue: https://github.com/Niko1221/Strata/issues/214 Setup run from a v0.1.27 checkout does not install a fixed v0.1.27 stack. It fetches: - the engine from `releases/latest` ([setup.py#L56](https://github.com/Niko1221/Strata/blob/a79080535d1b2a71a3419a0d97d8e7dca194b0f1/setup.py#L56)), i.e. whichever release is newest when setup runs; - the model shards and mmproj from each Hugging Face repo's `main` ([#L49](https://github.com/Niko1221/Strata/blob/a79080535d1b2a71a3419a0d97d8e7dca194b0f1/setup.py#L49), [#L83-L100](https://github.com/Niko1221/Strata/blob/a79080535d1b2a71a3419a0d97d8e7dca194b0f1/setup.py#L83-L100)), and the MTP tensors from `Qwen/Qwen3.8-Flash-Next` at `main` ([tools/mtp_fetch.py#L22](https://github.com/Niko1221/Strata/blob/a79080535d1b2a71a3419a0d97d8e7dca194b0f1/tools/mtp_fetch.py#L22)); - `numpy, jinja2, regex, pyyaml, tqdm, requests, cmake, ninja, pillow, psutil` without versions ([setup.py#L62](https://github.com/Niko1221/Strata/blob/a79080535d1b2a71a3419a0d97d8e7dca194b0f1/setup.py#L62)). So the same checkout can install different components from one day to the next, and once a newer release is out, an older checkout's `serve/` runs against a newer engine than the one it shipped with. We needed a reproducible install, so we passed `--prebuilt <local folder>` and `--gguf-dir` with files fetched at fixed revisions, and pointed `tools/mtp_fetch.py`'s `REPO` at a fixed revision, since there is no option for it. Suggestions: - default `--prebuilt` to the release that matches the checkout (`releases/download/v<version>/`, with the version `source_version()` already reads from CMakeLists.txt), falling back to `releases/latest` when that release does not exist; - pin each Hugging Face URL to a commit (`resolve/<commit>/`) in the model table and in `mtp_fetch.py`, or accept one as an option; - pin the Python packages (a requirements file with versions, optionally hashes).
Author
Owner

@Niko1221 commented on GitHub (Sep 30, 2026):

Agreed, those are real. Setup will fetch the engine matching the checkout's version first (latest as the fallback), and we'll pin the Hugging Face revisions and the Python package versions. Not in 0.1.28 yet.

<!-- gh-comment-id:5908111335 --> @Niko1221 commented on GitHub (Sep 30, 2026): Agreed, those are real. Setup will fetch the engine matching the checkout's version first (latest as the fallback), and we'll pin the Hugging Face revisions and the Python package versions. Not in 0.1.28 yet.
Author
Owner

@alphastorm commented on GitHub (Sep 30, 2026):

Thanks for the quick replies @Niko1221 - if it's easier for you I'm happy to open PRs for my issues that aren't already in 0.1.28, just let me know! 🙏

<!-- gh-comment-id:5908145207 --> @alphastorm commented on GitHub (Sep 30, 2026): Thanks for the quick replies @Niko1221 - if it's easier for you I'm happy to open PRs for my issues that aren't already in `0.1.28`, just let me know! 🙏
Author
Owner

@Niko1221 commented on GitHub (Sep 30, 2026):

Agreed. 0.1.31: setup downloads the engine for the checkout's version first (latest only as a fallback), pins the Hugging Face revisions, and installs the Python packages from a pinned requirements file. If you already have a PR for part of this, feel free to open it.

<!-- gh-comment-id:5917513247 --> @Niko1221 commented on GitHub (Sep 30, 2026): Agreed. 0.1.31: setup downloads the engine for the checkout's version first (latest only as a fallback), pins the Hugging Face revisions, and installs the Python packages from a pinned requirements file. If you already have a PR for part of this, feel free to open it.
Author
Owner

@Niko1221 commented on GitHub (Oct 1, 2026):

0.1.31: setup downloads the engine for the checkout's own version first (latest only as a fallback, with a message), pins the Hugging Face revisions, and installs the Python packages from a pinned requirements.txt. Thanks!

<!-- gh-comment-id:5925212891 --> @Niko1221 commented on GitHub (Oct 1, 2026): [0.1.31](https://github.com/Niko1221/Strata/releases/tag/v0.1.31): setup downloads the engine for the checkout's own version first (latest only as a fallback, with a message), pins the Hugging Face revisions, and installs the Python packages from a pinned `requirements.txt`. Thanks!
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
Niko1221/Strata#114
No description provided.