-
Notifications
You must be signed in to change notification settings - Fork 92
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[MAIN] update gh-action runner from macOS12 to macOS14 (#651)
* the macOS-12 environment is deprecated, switching to macOS-13, macOS-14 (macos-latest) or macOS-15. * remove defaults channel from conda * update setup mini-conda * set remove defaults channel to true * set conda forge as channel * update cache action to v4 * update upload artifact action * merge all wheels into one artifact
- Loading branch information
1 parent
123ca04
commit 7fa7bc9
Showing
2 changed files
with
26 additions
and
14 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -134,7 +134,7 @@ jobs: | |
fail-fast: false | ||
matrix: | ||
# OS [ubuntu-latest, macos-latest, windows-latest] | ||
os: [macos-12,macos-13] | ||
os: [macos-13,macos-14] | ||
python-version: [3.11] | ||
steps: | ||
- name: Get current year-month | ||
|
@@ -144,7 +144,7 @@ jobs: | |
- uses: actions/[email protected] | ||
|
||
- name: Cache conda | ||
uses: actions/cache@v3 | ||
uses: actions/cache@v4 | ||
with: | ||
path: ~/conda_pkgs_dir | ||
key: ${{ runner.os }}-conda-${{hashFiles('requirements/environment.yml') }}-${{ hashFiles('**/CI.yml') }}-${{ steps.date.outputs.date }} | ||
|
@@ -162,15 +162,16 @@ jobs: | |
key: datasets-${{ steps.elephant-data.outputs.dataset_hash }} | ||
restore-keys: datasets- | ||
|
||
- uses: conda-incubator/setup-miniconda@a4260408e20b96e80095f42ff7f1a15b27dd94ca # corresponds to v3.0.4 | ||
- uses: conda-incubator/setup-miniconda@d2e6a045a86077fb6cad6f5adf368e9076ddaa8d # corresponds to v3.1.0 | ||
with: | ||
auto-update-conda: true | ||
python-version: ${{ matrix.python-version }} | ||
mamba-version: "*" | ||
channels: conda-forge,defaults | ||
channels: conda-forge | ||
channel-priority: true | ||
activate-environment: elephant | ||
environment-file: requirements/environment-tests.yml | ||
conda-remove-defaults: true | ||
|
||
- name: Install dependencies | ||
shell: bash -l {0} | ||
|
@@ -363,7 +364,7 @@ jobs: | |
echo "dir=$(pip cache dir)" >> $GITHUB_OUTPUT | ||
- name: Cache pip | ||
uses: actions/cache@v3 | ||
uses: actions/cache@v4 | ||
with: | ||
path: ${{ steps.pip-cache.outputs.dir }} | ||
|
||
|
@@ -383,22 +384,22 @@ jobs: | |
restore-keys: datasets- | ||
enableCrossOsArchive: true | ||
|
||
- uses: conda-incubator/setup-miniconda@030178870c779d9e5e1b4e563269f3aa69b04081 # corresponds to v3.0.3 | ||
- uses: conda-incubator/setup-miniconda@d2e6a045a86077fb6cad6f5adf368e9076ddaa8d # corresponds to v3.1.0 | ||
with: | ||
auto-update-conda: true | ||
python-version: ${{ matrix.python-version }} | ||
mamba-version: "*" | ||
channels: conda-forge,defaults | ||
channels: conda-forge | ||
channel-priority: true | ||
activate-environment: elephant | ||
environment-file: requirements/environment-tests.yml | ||
conda-remove-defaults: true | ||
|
||
- name: Install dependencies | ||
shell: bash -el {0} | ||
run: | | ||
python --version | ||
conda install mpi4py openmpi | ||
mamba install pytest pytest-cov coveralls | ||
mamba install -c conda-forge pytest pytest-cov coveralls mpi4py openmpi | ||
pip install -e . | ||
- name: List packages | ||
|
@@ -448,28 +449,29 @@ jobs: | |
echo "dir=$(pip cache dir)" >> $GITHUB_OUTPUT | ||
- name: Cache pip | ||
uses: actions/cache@v3 | ||
uses: actions/cache@v4 | ||
with: | ||
path: ${{ steps.pip-cache.outputs.dir }} | ||
# Look to see if there is a cache hit for the corresponding requirements files | ||
key: ${{ runner.os }}-pip-${{ hashFiles('**/requirements-docs.txt') }}-${{ hashFiles('**/requirements-tutorials.txt') }}-${{ hashFiles('**/environment-docs.yml') }} | ||
-${{ hashFiles('**/CI.yml') }}-${{ steps.date.outputs.date }} | ||
|
||
- uses: conda-incubator/setup-miniconda@030178870c779d9e5e1b4e563269f3aa69b04081 # corresponds to v3.0.3 | ||
- uses: conda-incubator/setup-miniconda@d2e6a045a86077fb6cad6f5adf368e9076ddaa8d # corresponds to v3.1.0 | ||
with: | ||
auto-update-conda: true | ||
python-version: ${{ matrix.python-version }} | ||
mamba-version: "*" | ||
activate-environment: elephant | ||
environment-file: requirements/environment.yml | ||
conda-remove-defaults: true | ||
|
||
- name: Install dependencies | ||
shell: bash -el {0} # enables conda incubator to activate environment | ||
run: | | ||
sudo apt-get update | ||
sudo apt install -y libopenmpi-dev openmpi-bin | ||
conda install -c conda-forge openmpi pandoc libstdcxx-ng # fix libstdc++.so.6: version for new scipy versions > 1.9.1 | ||
mamba install -c conda-forge openmpi pandoc libstdcxx-ng # fix libstdc++.so.6: version for new scipy versions > 1.9.1 | ||
mamba env update --file requirements/environment-docs.yml --name elephant | ||
python -m pip install --upgrade pip | ||
pip install -e .[extras,tutorials,docs] | ||
|
@@ -513,7 +515,7 @@ jobs: | |
python-version: ${{ matrix.python-version }} | ||
|
||
- name: Cache test_env | ||
uses: actions/cache@v3 | ||
uses: actions/cache@v4 | ||
with: | ||
path: ~/test_env | ||
# Look to see if there is a cache hit for the corresponding requirements files | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters