Python environment dependency resolution
Use when when you have cloned a Python project repository and need to set up a working environment with all required packages, or when requirements.txt exists but dependencies are not yet installed in your current Python environment.From its SKILL.md
npx -y skills add HolobiomicsLab/asb-skill-collections --skill python-environment-dependency-resolutionAssembled from the repository path, not quoted from the project. Check it against their README if it does not work.
One thing to look at
- 15 stars15 stars. Stars are a popularity signal and not a quality one, but at this level it is likely that nobody has read this closely except its author, and you would be relying on your own review.
What its file declares
Copied from the file, not written here
The file declares its own license as CC-BY-4.0. That is the author’s claim about this one file, and it is not the same thing as the license GitHub reports for the repository, which is listed with the other numbers below.
SKILL.md
6.1 KB, 976 tokens by cl100k_base, as published. Nobody here has run it
Python Environment Dependency Resolution
Summary
Resolve and install Python package dependencies declared in a requirements.txt file using pip, enabling creation of an importable and reproducible Python environment. This skill ensures all necessary libraries are available before executing code that depends on them.
When to use
When you have cloned a Python project repository and need to set up a working environment with all required packages, or when requirements.txt exists but dependencies are not yet installed in your current Python environment. Specifically triggered when attempting to import a package fails with ModuleNotFoundError, or when documentation instructs environment setup before proceeding to analysis or tutorial steps.
When NOT to use
- If you are using a different package manager (e.g., conda with environment.yml, or Poetry with pyproject.toml); use the package manager native to the project instead.
- If the requirements.txt file is missing or the project uses a setup.py-only distribution; use 'pip install -e .' or 'pip install .' to install from the project's setup configuration.
- If you need to pin versions for reproducibility across machines and environments; use a locked requirements file (e.g., requirements-lock.txt generated by pip-freeze or pip-tools) instead.
Inputs
- requirements.txt file (text file with one Python package specification per line)
- Active Python environment (conda, venv, or system Python)
- Network access to PyPI (Python Package Index)
Outputs
- Installed Python packages in the target environment
- Updated site-packages directory with all dependencies
- Importable module namespace matching requirements.txt declarations
How to apply
Locate the requirements.txt file in the project root directory. Execute 'pip install -r requirements.txt' from the command line within the target Python environment (activate the conda/virtual environment first if using one). The pip tool parses the requirements.txt file to identify all declared package names and version constraints, then downloads and installs them from PyPI. Verify successful installation by attempting to import each key package in a Python interpreter. If installation fails, check that pip and setuptools are up-to-date, that the requirements.txt syntax is valid (one package per line, with optional version specifiers like ==, >=, or <), and that you have internet access to PyPI.
Related tools
- pip (Package installer and dependency resolver that reads requirements.txt and installs packages from PyPI) — https://pip.pypa.io/en/stable/
- conda (Alternative environment and package manager; useful if requirements.txt contains non-Python dependencies or if conda-specific packages are needed) — https://conda.io/projects/conda/en/latest/
Examples
pip install -r requirements.txt
Evaluation signals
- No error messages or warnings when running 'pip install -r requirements.txt'
- Successful import of key packages in Python interpreter (e.g., 'python -c "import dreams"' or 'python -c "import ppiref"')
- Output of 'pip list' shows all packages from requirements.txt with matching or compatible versions
- Tutorial or downstream workflow scripts run without ModuleNotFoundError
- Version constraints in requirements.txt are satisfied (verify with 'pip show <package>')
Limitations
- requirements.txt may reference outdated or pinned versions that conflict with other packages in the environment; resolving such conflicts may require manual version negotiation or use of a more sophisticated resolver like pip-tools.
- Platform-specific or compiled packages (e.g., PyTorch with CUDA support) may require additional configuration beyond pip install; check project documentation for platform-specific installation steps.
- Transitive dependencies (dependencies of dependencies) are handled automatically by pip, but if requirements.txt does not pin indirect dependencies, different installation orders or times may yield different resolved versions.
- Network connectivity and PyPI availability are required; installation will fail if PyPI is unreachable or if a package has been removed from PyPI.
Evidence
- [other] DreaMS Python dependencies are declared in a requirements.txt file and can be installed using pip with the command 'pip install -r requirements.txt'.: "DreaMS Python dependencies are declared in a requirements.txt file and can be installed using pip with the command 'pip install -r requirements.txt'."
- [methods] pip install -r requirements.txt as documented workflow step for dependency installation: "Install requirements [section=methods; evidence='pip install -r requirements.txt']"
- [readme] Installation instructions in DreaMS README showing environment setup followed by pip install -e: "# Install DreaMS pip install -e ."
- [readme] PPIRef installation workflow using pip install with editable mode: "git clone https://github.com/anton-bushuiev/PPIRef.git cd PPIRef; pip install -e ."
What ships with it
Read from the repository
Just SKILL.md. No reference files, no scripts.