-
Notifications
You must be signed in to change notification settings - Fork 71
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Setup conda step takes too long #89
Comments
Hi @ma-sadeghi, thanks for the kind words and for using the action :)
Has this changed in any newer version? When did you notice started noticing this? Just wondering so we can pinpoint to any potential issue. @conda-incubator/setup-miniconda-team have you noticed anything similiar as described? |
Same issue for me using mamba (without installing my deps during the action) and with the latest v2 version. |
@bollwyvl I could use hand debugging this |
In case it helps (I can't share the logs): steps:
- name: Checkout the code
uses: actions/checkout@v2
- name: Cache conda
uses: actions/cache@v1
env:
CACHE_NUMBER: 2
with:
path: ~/conda_pkgs_dir
key: conda-${{ runner.os }}-${{ env.CACHE_NUMBER }}-${{ hashFiles('env.yml') }}
- name: Setup conda
uses: conda-incubator/setup-miniconda@v2
with:
mamba-version: "*"
channels: conda-forge,defaults
channel-priority: true
use-only-tar-bz2: true |
Thanks @hadim for the example. Will add a PR to check the changes that introduced the regression. |
I'm almost sure that it used to be much quicker the first time I used this Action, off the top of my head, maybe it took 1 minute or so setting up conda, now it's at 3:30 minutes. Our project is public, and it's been a while since we're using this Action, so feel free to check out our logs in case that helps debugging the issue: https://github.com/PMEAL/OpenPNM/actions |
From the linked logs:
So we have, somewhat unscientifically:
The only thing I can think of is Some options, off the top of my head:
|
For what it's worth most of the time is spent installing mamba: Associated config: - name: Cache conda
uses: actions/cache@v2
env:
CACHE_NUMBER: 3
with:
path: ~/conda_pkgs_dir
key: conda-${{ runner.os }}-${{ env.CACHE_NUMBER }}-${{ hashFiles('env.yml') }}
- name: Setup conda
uses: conda-incubator/setup-miniconda@v2
with:
python-version: 3.7
mamba-version: "*"
channels: conda-forge,defaults
channel-priority: true
use-only-tar-bz2: true
activate-environment: nova Is that possible to use something like micromamba instead of miniconda or miniforge? |
Looking at the detail the solving step is what takes 99% of the time. |
If this issue gets addressed, the miniforge route will provide this by default :D |
I confirm the recently released MambaForge installer makes the CI faster: - name: Setup conda
uses: conda-incubator/setup-miniconda@v2
with:
installer-url: https://github.com/conda-forge/miniforge/releases/download/4.9.2-2/Mambaforge-Linux-x86_64.sh
channel-priority: true
use-only-tar-bz2: true
activate-environment: my-env
- name: Anaconda Login
run: |
# Bypass the installation of anaconda-client
TOKEN_DIR="$HOME/.config/binstar"
TOKEN_PATH="$TOKEN_DIR/https%3A%2F%2Fapi.anaconda.org.token"
mkdir -p $TOKEN_DIR
echo -e "${ANACONDA_USER_TOKEN}\c" > $TOKEN_PATH
- name: Install Dependencies
run: mamba env update -f env.yml (the snippet also includes a way to login to anaconda without the need to install |
How does it play with |
Good question and I actually don't know. The new installer ships I need to first login to anaconda first (see snippet) so I don't rely on I guess if you want to use Maybe someone from @conda-incubator/setup-miniconda-team can confirm or not? |
There are a lot more moving pieces coming up now than just use what's on disk vs get an installer from a URL with a scheme we've been able to predict for half a decade, and the current code's behavior w/r/t to I'll wager, if you provide a Anyhow, I felt fixing some of these issues requires some pretty drastic restructuring... on #107 (which is becoming #108, #109, ... pending review) I made a best effort attempt at getting us set up for The Next X, where X can be a one/two file PR. Hopefully we can get to where we can start adding features and addressing performance, but I fear not addressing the current technical debt first is going to make the situation worse. |
miniforge-variable: Mambaforge
use-mamba: true Which should mostly answer the mail here... to the extent that a full conda+python+mamba install can. Micromamba has had a lot of updates recently, but I still haven't been able to evaluate it as to whether we want to support/test it to the same level as the other providers, yet... |
Thank you for creating/maintaining this great Action!
It seems that setting up
conda
alone takes longer than usual. For example, take a look at this log, the "Set up conda" step. It takes 3 and a half minutes setting up conda (excluding the installation of dependencies). Is that expected or am I doing something wrong?Thank you once again!
The text was updated successfully, but these errors were encountered: