feat(sandboxed-gym): Install dependencies from wheels in Gym host runtime - #1522
Open
JashG wants to merge 3 commits into
Open
feat(sandboxed-gym): Install dependencies from wheels in Gym host runtime#1522JashG wants to merge 3 commits into
JashG wants to merge 3 commits into
Conversation
Signed-off-by: Jash Gulabrai <jgulabrai@nvidia.com>
JashG
commented
Aug 25, 2026
| COPY packages/sandboxed_gym/src /opt/sandboxed_gym/src | ||
| RUN pip install --no-cache-dir --no-deps /opt/sandboxed_gym && pip install --no-cache-dir "pydantic>=2.10.0" | ||
| RUN pip install --no-cache-dir --no-deps /opt/sandboxed_gym \ | ||
| && pip install --no-cache-dir "pydantic>=2.10.0" "pyyaml>=6.0.2" |
Contributor
Author
There was a problem hiding this comment.
pyyaml is for parsing the nemo-environment.yaml file.
… deps are importable Signed-off-by: Jash Gulabrai <jgulabrai@nvidia.com>
Signed-off-by: Jash Gulabrai <jgulabrai@nvidia.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.
Summary
Adds
wheels-v1dependency installation to the sandboxed Gym host runtime. Before Gym starts, the runtime installs vendored wheels from the read-only environment mount into writable job storage and ensures Gym’s per-server environments resolve their requirements from those wheels without accessing a package index.This PR depends on #1400.
Changes
Runtime behavior
nemo-environment.yamlmanifests using thewheels-v1format. Install wheels from the read-only environment mount into writable job storage before Gym starts.sys.pathand to child processes throughPYTHONPATH.UV_FIND_LINKSandUV_NO_INDEXso Gym’s per-server environments resolve theirrequirements.txtdependencies exclusively from the staged wheelhouse.Runtime dependencies
sandboxed-gym[runtime]extra containing PyYAML.Test coverage
uvconfiguration, import-path propagation, and bootstrap ordering.uvexecutable without Docker or external package downloads.requirements.txtinstallation resolves from the staged wheelhouse with package-index access disabled.Type of Change
Quality Gates
Verification
Signed-off-by:traileruv run pre-commit run -apasses, or any blocked checks are identified belowTargeted validation:
uv run --project packages/sandboxed_gym --extra dev pytest packages/sandboxed_gym/tests/test_gym_host_runtime.py packages/sandboxed_gym/tests/test_wheels_v1_install_integration.py -q25 passeduv run ruff check packages/sandboxed_gym/src/sandboxed_gym/runtime/gym_host_runtime.py packages/sandboxed_gym/tests/test_gym_host_runtime.py packages/sandboxed_gym/tests/test_wheels_v1_install_integration.pyuv run ruff format --check packages/sandboxed_gym/src/sandboxed_gym/runtime/gym_host_runtime.py packages/sandboxed_gym/tests/test_gym_host_runtime.py packages/sandboxed_gym/tests/test_wheels_v1_install_integration.pyuv run pre-commit run -a