The Colab no-venv path in setup.sh (added in #4601, modified in #4618)
only installs studio.txt (fastapi, uvicorn, structlog, etc.) into
system Python. It skips install_python_stack entirely via
_SKIP_PYTHON_DEPS=true, which means base.txt (unsloth + unsloth-zoo),
extras.txt, extras-no-deps.txt (trl, transformers, sentence_transformers),
and overrides.txt (torchao) are never installed.
When the training worker subprocess spawns and tries to import unsloth,
unsloth/__init__.py calls importlib.metadata.version("unsloth_zoo")
which raises PackageNotFoundError, surfaced as:
"Failed to import ML libraries: Please install unsloth_zoo"
Even if unsloth_zoo were installed, the next failure would be trl
(imported at trainer.py:63) since it lives in extras-no-deps.txt.
Fix: install all four requirement groups in the Colab block, matching
what install_python_stack.py does for the normal venv path:
- base.txt (unsloth + unsloth-zoo) -- fail-fast on error
- extras.txt (version-stripped to avoid Colab conflicts)
- extras-no-deps.txt (trl, transformers, sentence_transformers)
- overrides.txt (torchao)
Only the Colab code path is changed. Non-Colab paths are untouched.