Skip to content

MILAB-7089: Pin pgen runenv to the Generation Probability set - #110

Merged
kevindetry-milaboratories merged 1 commit into
mainfrom
MILAB-7089-pgen-block-pins
Oct 1, 2026
Merged

kevindetry-milaboratories merged 1 commit into
mainfrom
MILAB-7089-pgen-block-pins

Conversation

@kevindetry-milaboratories

@kevindetry-milaboratories kevindetry-milaboratories commented Oct 1, 2026 •

Copy link
Copy Markdown
Contributor

Problem

The Generation Probability block fails on a backend without Docker, such as the desktop built-in backend (MILAB-7089):

ERROR: Could not find a version that satisfies the requirement llvmlite==0.48.0 (from versions: 0.44.0, 0.47.0)

Without Docker, the backend installs the block's requirements.txt offline: pip install --no-index --find-links {runenv}/packages/ (platforma/sdk/workflow-tengo/src/exec/python/install-deps.tpl.tengo). Every pin must exist as a wheel in the run environment. Docker mode installs from PyPI, so it does not show the mismatch.

The 3.12.10-pgen variant was made for this block, but its set (numpy==2.2.6, polars-lts-cpu==1.33.1) does not match the block pins.

Change

  • Pin the 7 block packages: olga==1.3.0, numba==0.66.0, llvmlite==0.48.0, numpy==2.4.6, polars==1.43.0, polars-runtime-32==1.43.0, polars-runtime-compat==1.43.0.
  • Remove polars-lts-cpu. polars[rtcompat] replaces it upstream. The builder does not support extras in a spec, so each package is pinned.
  • Put olga and numba under noDeps. Without it, pip download olga==1.3.0 also saves numba-0.68.0, llvmlite-0.50.0 and numpy-2.5.3. The hilary variant does the same.
  • Turn on strictMissing, so a missing wheel fails the build instead of a broken runenv.
  • README: the pin contract, the glibc 2.28 floor from numpy 2.4.6, and a fix of the old note about the numba fast path (the block uses FastPgen).

The changeset bumps runenv-python-3.12.10-pgen (minor). The catalogue gets a patch bump through internal dependencies.

Tests

  • Local linux-x64 build with the real builder image (podman): portable Python 3.12.10, all pins resolved as binary wheels, native import checker passed. packages/ has exactly the 7 wheels.
  • Local backend 4.4.5 with Docker off, with the block's real pgen-process template and this runenv: the offline pip install passed, main.py ran without Docker, all pgen values were non-null.
  • Contrast with the base 3.12.10 runenv: the same llvmlite==0.48.0 error as the ticket.
  • pip download --only-binary :all: for win_amd64, macosx_13_0_arm64, macosx_15_0_arm64 and manylinux_2_28_aarch64: the same 7 versions. Not run on Windows or macOS.

Follow-up

After this is published, the block bumps its @platforma-open/milaboratories.runenv-python-3 catalog pin to the new catalogue version and moves to 3.12.10-pgen. That PR also changes the block's forkserver workers to spawn (Windows has no forkserver, and the socket path can be too long on Linux and macOS).

RetriggerConfidence Score: 5/5

The PR appears safe to merge; no actionable defect was established.

Summary

The PR aligns the pgen runtime’s bundled wheels with the Generation Probability block’s stated offline-install pins, replaces polars-lts-cpu, and makes missing wheels fail the build.

Key touched terms: 3.12.10-pgen is the dedicated Python runtime; its package set changes. olga computes generation probabilities; it remains at 1.3.0 and gains noDeps. numba accelerates Olga’s fast path and llvmlite supports Numba; both gain explicit pins. numpy supplies numerical operations; its pin moves to 2.4.6. polars supplies dataframe and Parquet support; it replaces polars-lts-cpu alongside pinned polars-runtime-32 and polars-runtime-compat wheels. noDeps suppresses transitive downloads for selected packages; strictMissing fails a build when resolution cannot supply a required wheel.

Diagram
%%{init: {'theme': 'neutral'}}%%
flowchart LR
  A[pgen package pins] --> B[Builder downloads wheels]
  B --> C{Required wheel missing?}
  C -->|Yes| D[Build fails]
  C -->|No| E[Published runenv packages]
  E --> F[Block installs requirements offline]
Loading

Reviews (1) · Last reviewed commit: "Pin pgen runenv to the Generation Probab..."

The Generation Probability block installs its `requirements.txt` with
`pip --no-index --find-links <runenv packages>` on a backend without
Docker. Every pin must exist as a wheel in the run environment.

- Pin `olga`, `numba`, `llvmlite`, `numpy`, `polars`,
  `polars-runtime-32` and `polars-runtime-compat` to the block versions.
- Remove `polars-lts-cpu`. `polars[rtcompat]` replaces it upstream.
- Put `olga` and `numba` under `noDeps`, so their loose requirements
  do not add newer duplicate wheels.
- Turn on `strictMissing`, so a missing wheel fails the build.
@kevindetry-milaboratories
kevindetry-milaboratories merged commit 6a9635a into main Oct 1, 2026
73 checks passed
@kevindetry-milaboratories
kevindetry-milaboratories deleted the MILAB-7089-pgen-block-pins branch October 1, 2026 15:58
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