Skip to content

Look into using mamba instead of conda for CI jobs #1472

Closed
@kandersolar

Description

@kandersolar

Is your feature request related to a problem? Please describe.
One step in our pytest CI jobs is setting up a conda environment. Setting up that environment can be a large fraction of total job execution time. Here's an example job run where 5 out of the total 8 minutes were spent setting up the conda environment. It would be nice to speed this up somehow; faster jobs means less time spent twiddling thumbs waiting for tests to pass and are a more responsible use of the free CI services GitHub provides to us.

Describe the solution you'd like
Mamba is supposedly a faster drop-in replacement for conda, so using mamba instead of conda in our CI jobs might speed them up without much hassle.

As suggested by @wholmgren in #1306 (comment), the micromamba github action might be one way to do this. This method pandas uses seems worth exploring too: https://github.com/pandas-dev/pandas/blob/3b6015f24f088597846c757b1e9f85e6e379ece7/.github/actions/setup-conda/action.yml#L35

Describe alternatives you've considered
Cached environments may be another option. In general I am wary of persisting anything between CI sessions for fear of introducing some difficult-to-debug state issue, but if it can be done robustly then it may be worthwhile here.

Additional context
Starting with the pytest jobs probably makes the most sense, but it might be possible to use mamba for the asv job as well. But see airspeed-velocity/asv#970

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions