Skip to content

Commit 0eeaed9

Browse files
committed
Remove python-specific conda environments
1 parent 307913d commit 0eeaed9

File tree

6 files changed

+25
-37
lines changed

6 files changed

+25
-37
lines changed

.github/workflows/test.yml

+21-17
Original file line numberDiff line numberDiff line change
@@ -17,8 +17,9 @@ jobs:
1717
ubuntu:
1818
strategy:
1919
matrix:
20-
os: [ubuntu-18.04]
21-
floatx: [float32, float64]
20+
os: [ubuntu-latest]
21+
floatx: [float64]
22+
python-version: ["3.8"]
2223
test-subset:
2324
- pymc_experimental/tests
2425
fail-fast: false
@@ -34,12 +35,12 @@ jobs:
3435
- name: Cache conda
3536
uses: actions/cache@v1
3637
env:
37-
# Increase this value to reset cache if environment-test-py38.yml has not changed
38+
# Increase this value to reset cache if environment-test.yml has not changed
3839
CACHE_NUMBER: 0
3940
with:
4041
path: ~/conda_pkgs_dir
41-
key: ${{ runner.os }}-conda-${{ env.CACHE_NUMBER }}-${{
42-
hashFiles('conda-envs/environment-test-py38.yml') }}
42+
key: ${{ runner.os }}-py${{matrix.python-version}}-conda-${{ env.CACHE_NUMBER }}-${{
43+
hashFiles('conda-envs/environment-test.yml') }}
4344
- name: Cache multiple paths
4445
uses: actions/cache@v2
4546
env:
@@ -57,19 +58,20 @@ jobs:
5758
miniforge-variant: Mambaforge
5859
miniforge-version: latest
5960
mamba-version: "*"
60-
activate-environment: pymc-test-py38
61+
activate-environment: pymc-test
6162
channel-priority: strict
62-
environment-file: conda-envs/environment-test-py38.yml
63+
environment-file: conda-envs/environment-test.yml
64+
python-version: ${{matrix.python-version}}
6365
use-mamba: true
6466
use-only-tar-bz2: true # IMPORTANT: This needs to be set for caching to work properly!
6567
- name: Install-pymc
6668
run: |
67-
conda activate pymc-test-py38
69+
conda activate pymc-test
6870
pip install -e .
6971
python --version
7072
- name: Run tests
7173
run: |
72-
conda activate pymc-test-py38
74+
conda activate pymc-test
7375
python -m pytest -vv --cov=pymc_experimental --cov-append --cov-report=xml --cov-report term --durations=50 $TEST_SUBSET
7476
- name: Upload coverage to Codecov
7577
uses: codecov/codecov-action@v2
@@ -81,7 +83,8 @@ jobs:
8183
strategy:
8284
matrix:
8385
os: [windows-latest]
84-
floatx: [float32, float64]
86+
floatx: [float32]
87+
python-version: ["3.10"]
8588
test-subset:
8689
- pymc_experimental/tests
8790
fail-fast: false
@@ -97,12 +100,12 @@ jobs:
97100
- name: Cache conda
98101
uses: actions/cache@v1
99102
env:
100-
# Increase this value to reset cache if conda-envs/environment-test-py37.yml has not changed
103+
# Increase this value to reset cache if conda-envs/windows-environment-test.yml has not changed
101104
CACHE_NUMBER: 0
102105
with:
103106
path: ~/conda_pkgs_dir
104-
key: ${{ runner.os }}-conda-${{ env.CACHE_NUMBER }}-${{
105-
hashFiles('conda-envs/windows-environment-test-py37.yml') }}
107+
key: ${{ runner.os }}-py${{matrix.python-version}}-conda-${{ env.CACHE_NUMBER }}-${{
108+
hashFiles('conda-envs/windows-environment-test.yml') }}
106109
- name: Cache multiple paths
107110
uses: actions/cache@v2
108111
env:
@@ -120,21 +123,22 @@ jobs:
120123
miniforge-variant: Mambaforge
121124
miniforge-version: latest
122125
mamba-version: "*"
123-
activate-environment: pymc-test-py37
126+
activate-environment: pymc-test
124127
channel-priority: strict
125-
environment-file: conda-envs/windows-environment-test-py37.yml
128+
environment-file: conda-envs/windows-environment-test.yml
129+
python-version: ${{matrix.python-version}}
126130
use-mamba: true
127131
use-only-tar-bz2: true # IMPORTANT: This needs to be set for caching to work properly!
128132
- name: Install-pymc
129133
run: |
130-
conda activate pymc-test-py37
134+
conda activate pymc-test
131135
pip install -e .
132136
python --version
133137
- name: Run tests
134138
# This job uses a cmd shell, therefore the environment variable syntax is different!
135139
# The ">-" in the next line replaces newlines with spaces (see https://stackoverflow.com/a/66809682).
136140
run: >-
137-
conda activate pymc-test-py37 &&
141+
conda activate pymc-test &&
138142
python -m pytest -vv --cov=pymc_experimental --cov-append --cov-report=xml --cov-report term --durations=50 %TEST_SUBSET%
139143
- name: Upload coverage to Codecov
140144
uses: codecov/codecov-action@v2

.gitpod.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ tasks:
55
mkdir -p .vscode
66
echo '{"python.defaultInterpreterPath": "/workspace/pymc-experimental/env/bin/python"}' > .vscode/settings.json
77
conda init bash && source ~/.bashrc
8-
conda env update -f conda-envs/environment-test-py39.yml -p env
8+
conda env update -f conda-envs/environment-test.yml -p env
99
conda activate /workspace/pymc-experimental/env
1010
pip install -r requirements-dev.txt
1111
pip install -e .

conda-envs/environment-test-py39.yml

-14
This file was deleted.

conda-envs/environment-test-py38.yml renamed to conda-envs/environment-test.yml

+1-2
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,11 @@
1-
name: pymc-test-py38
1+
name: pymc-test
22
channels:
33
- conda-forge
44
- defaults
55
dependencies:
66
- pip
77
- pytest-cov>=2.5
88
- pytest>=3.0
9-
- python=3.8
109
- dask
1110
- xhistogram
1211
- pip:

conda-envs/windows-environment-test-py37.yml renamed to conda-envs/windows-environment-test.yml

+1-2
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,11 @@
1-
name: pymc-test-py310
1+
name: pymc-test
22
channels:
33
- conda-forge
44
- defaults
55
dependencies:
66
- pip
77
- pytest-cov>=2.5
88
- pytest>=3.0
9-
- python=3.10
109
- dask
1110
- xhistogram
1211
- pip:

setup.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -29,9 +29,9 @@
2929
"Development Status :: 5 - Production/Stable",
3030
"Programming Language :: Python",
3131
"Programming Language :: Python :: 3",
32-
"Programming Language :: Python :: 3.7",
3332
"Programming Language :: Python :: 3.8",
3433
"Programming Language :: Python :: 3.9",
34+
"Programming Language :: Python :: 3.10",
3535
"License :: OSI Approved :: Apache Software License",
3636
"Intended Audience :: Science/Research",
3737
"Topic :: Scientific/Engineering",

0 commit comments

Comments
 (0)