Design issue: [[git_repos]] mount_as creates fragile version mismatch
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 99
- Forks
- 62
- Avg merge
- 6d 12h
- Merged PRs (30d)
- 17
Description
Summary
The [[git_repos]] mechanism with mount_as creates a fragile setup where scripts from one version can call core libraries from another version, leading to hard-to-debug errors.
Problem
When using [[git_repos]] with mount_as, a partial override occurs:
- Container has built-in package (e.g., Megatron-Bridge v0.4.0rc0 at
/opt/Megatron-Bridge) - External git clone (e.g., v0.3.1) provides entry scripts via PYTHONPATH
- Scripts from v0.3.1 import core modules from container's v0.4.0rc0
This causes:
- ModuleNotFoundError - Different module structure between versions
- API mismatches - Functions/parameters differ between versions
- Silent failures - No validation that git repo version is compatible with container
Observed Errors
ModuleNotFoundError: No module named 'megatron.core'
ValueError: Currently there is no support for Pipeline parallelism with CPU offloading
Root Causes
- Partial mounting -
mount_asoverwrites some paths but not others - Two sources of truth -
[[git_repos]]commit vs container's built-in version - Implicit dependencies - No enforcement that versions match
Proposed Solutions
- Version validation - Validate git repo commit is compatible with container
- Full override or none -
mount_asmust override entire package or nothing - Container-only mode - Warn if
[[git_repos]]targets a package already in container - Deprecate partial mounts - Remove support for mounting over container paths
Environment
- CloudAI version: v1.6.beta6
- Container: nvcr.io/nvidian/nemo:26.04.rc2 (Megatron-Bridge v0.4.0rc0)
- External repo: Megatron-Bridge v0.3.1
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by tracing how the [[git_repos]] configuration and mount_as are processed, then reproduce the version-mismatch cases with the listed container and Megatron-Bridge versions. Compare package resolution and the observed errors. Done should mean that one agreed behavior prevents or clearly reports incompatible partial mounts, but the issue does not yet choose among its proposed solutions.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- docker, python
- Domain
- devops, infrastructure
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Quiet
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100