Modernize conda/mamba/micromamba instructions#709
Modernize conda/mamba/micromamba instructions#709maresb wants to merge 9 commits intopymc-labs:mainfrom
Conversation
Documentation build overview
Show files changed (3 files in total): 📝 3 modified | ➕ 0 added | ➖ 0 deleted
|
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #709 +/- ##
=======================================
Coverage 94.36% 94.36%
=======================================
Files 44 44
Lines 7591 7591
Branches 461 461
=======================================
Hits 7163 7163
Misses 264 264
Partials 164 164 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
Use raw docstrings (r""") for SpikeAndSlabPrior and HorseshoePrior so LaTeX math markup is not misinterpreted as Python escape sequences. Co-authored-by: Cursor <cursoragent@cursor.com>
Single source of truth for detecting the conda tool, creating the CausalPy environment, running commands via `run -n`, and troubleshooting outdated installations. Co-authored-by: Cursor <cursoragent@cursor.com>
Replace hardcoded mambaforge path and `conda activate` with tool-agnostic instructions. AGENTS.md now links to the python-environment skill; .cursor/rules/basic.mdc references `$CONDA_EXE run -n CausalPy`. Co-authored-by: Cursor <cursoragent@cursor.com>
Use plain `conda` as a generic placeholder (with a note that mamba or micromamba can be substituted). Replace `mamba env create` and `conda activate` with tool-agnostic commands. Offer both activate and subshell workflows for interactive development. Add micromamba install instructions as a fallback. Co-authored-by: Cursor <cursoragent@cursor.com>
Co-authored-by: Cursor <cursoragent@cursor.com>
Co-authored-by: Cursor <cursoragent@cursor.com>
Ensures make is available in the conda environment on all platforms, including minimal container images. Co-authored-by: Cursor <cursoragent@cursor.com>
Avoids relying on pip to install pre-commit during make setup. Co-authored-by: Cursor <cursoragent@cursor.com>
8d07e88 to
6b35d63
Compare
|
Please merge #710 first |
Co-authored-by: Cursor <cursoragent@cursor.com>
There was a problem hiding this comment.
Pull request overview
This pull request modernizes the conda/mamba/micromamba installation and environment management instructions throughout the repository. It replaces hardcoded mambaforge paths and fragmented setup instructions with a tool-agnostic approach that supports all three package managers. The changes introduce a new python-environment skill file as a single source of truth for environment setup, which is referenced by both AI agent configuration files and contributor documentation.
Changes:
- Added
makeandpre-committo environment.yml dependencies to support the standardized setup workflow - Created a new
.github/skills/python-environment/SKILL.mdskill file with standardized instructions for tool detection, environment creation, and command execution - Updated AGENTS.md and .cursor/rules/basic.mdc to reference the skill file instead of duplicating instructions
- Modernized CONTRIBUTING.md to use generic
condaplaceholder while supporting all three tools (conda/mamba/micromamba) - Updated installation documentation and error messages to mention all three package managers
- Fixed docstring format in variable_selection_priors.py to use raw strings for LaTeX math
Reviewed changes
Copilot reviewed 9 out of 9 changed files in this pull request and generated 1 comment.
Show a summary per file
| File | Description |
|---|---|
| environment.yml | Added make and pre-commit dependencies to support the development workflow |
| docs/source/index.md | Updated installation instructions to mention conda/mamba/micromamba options |
| causalpy/variable_selection_priors.py | Fixed docstrings to use raw strings (r""") for proper LaTeX rendering |
| causalpy/pymc_models.py | Updated ImportError messages to mention all three package managers |
| Makefile | Updated setup target comment to reference modern environment usage pattern |
| CONTRIBUTING.md | Comprehensive update with tool-agnostic instructions, micromamba installation fallback, and both activation and subshell workflows |
| AGENTS.md | Streamlined to reference the python-environment skill file for setup instructions |
| .github/skills/python-environment/SKILL.md | New centralized skill file with tool detection, environment setup, and troubleshooting |
| .cursor/rules/basic.mdc | Updated to reference AGENTS.md for CONDA_EXE detection |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
|
|
||
| ## Troubleshooting | ||
|
|
||
| If you hit issues with an outdated `mamba` or `micromamba`, you can self-update: `$CONDA_EXE self-update`. As of 2026-02-13, current versions are conda 26.1.0, mamba/micromamba 2.5.0. |
There was a problem hiding this comment.
The self-update command works for mamba and micromamba, but not for conda. If $CONDA_EXE is conda, the correct update command is conda update -n base conda, not conda self-update. Consider adding a conditional instruction or noting that this only applies to mamba/micromamba.
Summary
mambaforgepaths andconda activatewith tool-agnostic instructions supportingconda,mamba, ormicromambapython-environmentskill as the single source of truth for environment setup (tool detection, env creation, editable install,run -nusage).cursor/rules/basic.mdcnow link to the skill instead of duplicating instructionscondaas a generic placeholder, offers bothactivateand subshell workflows for interactive development, and includes micromamba install as a fallbackMade with Cursor