mamba-org / setup-micromamba

GitHub Action to set up micromamba
MIT License
105 stars 16 forks source link

micromamba list error when prefix is set to create-args #176

Closed ickc closed 12 months ago

ickc commented 12 months ago

I'm using a custom prefix by specifying it in create-args, but micromamba list emits an error expecting it in standard location: https://github.com/ickc/so-software-environment/actions/runs/6951330647/job/18913121490#step:5:1123

pavelzw commented 12 months ago

This is currently not supported. setup-micromamba needs to infer in some way how the environment is named. If the environment is being used in a custom prefix instead of the default location for named environments, this is not possible.

Is there a reason why you don't use

    - uses: mamba-org/setup-micromamba@v1
      with:
        environment-name: so-conda-${{ env.TODAYS_DATE }}
        micromamba-root-path: ${{ matrix.prefix }}
        environment-file: examples/so.yml

This would install the environment to ${{ matrix.path }}/envs/so-conda-${{ env.TODAYS_DATE }}.

ickc commented 12 months ago

Thanks, the extra piece of /envs/ is less ideal. I'll think about it.