diff --git a/.github/workflows/run-tests.yml b/.github/workflows/run-tests.yml
index 1b40fa0d106513a100e624b9c3b23e1305c98dcb..d60c50af87a4552bbb13523b2d4aa298c13f3641 100644
--- a/.github/workflows/run-tests.yml
+++ b/.github/workflows/run-tests.yml
@@ -6,42 +6,60 @@ jobs:
latest:
runs-on: ubuntu-latest
strategy:
+ fail-fast: false
matrix:
- python-version: [3.6, 3.7, 3.8, 3.9]
+ python-version: ["3.9", "3.10", "3.11", "3.12"]
steps:
- - uses: actions/checkout@v2
+ - uses: actions/checkout@v4
- name: Set up Python ${{ matrix.python-version }}
- uses: actions/setup-python@v1
+ uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}
- name: Install dependencies
run: |
+ python -m venv --system-site-packages env
+ source env/bin/activate
python -m pip install --upgrade pip
- pip install -r pip-requirements.txt
+ python -m pip install -r pip-requirements.txt
+ python --version
+ python -c 'import numpy; print(numpy.__version__)'
+ python -c 'import cython; print(cython.__version__)'
+ python ./setup.py develop
+ # python -m pip -vvv install -e .
+ # fails with "ModuleNotFoundError: No module named 'Cython'"
+ # running setup.py directly is just a workaround.
- name: run tests
run: |
- ./run-tests.py
+ source env/bin/activate
+ python run-tests.py --skip-setup
other-os:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [macos-latest, windows-latest]
- python-version: [3.8]
+ python-version: [3.12]
# have to copy steps from above, as anchors are currently
# not supported by github workflow (Jan 2020).
steps:
- - uses: actions/checkout@v2
+ - uses: actions/checkout@v4
- name: Set up Python ${{ matrix.python-version }}
- uses: actions/setup-python@v1
+ uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}
- name: Install dependencies
run: |
python -m pip install --upgrade pip
- pip install -r pip-requirements.txt
+ python -m pip install -r pip-requirements.txt
+ python --version
+ python -c 'import numpy; print(numpy.__version__)'
+ python -c 'import cython; print(cython.__version__)'
+ python ./setup.py develop
+ # python -m pip -vvv install -e .
+ # fails with "ModuleNotFoundError: No module named 'Cython'"
+ # running setup.py directly is just a workaround.
- name: run tests
run: |
- ./run-tests.py
+ python run-tests.py --skip-setup
diff --git a/pip-requirements.txt b/pip-requirements.txt
index 3d95037eb529a5e0fb0bb9949bb72c5842976b0d..c3a22c98ee5fdc316dad1970c7e6b8f791451a33 100644
--- a/pip-requirements.txt
+++ b/pip-requirements.txt
@@ -2,7 +2,7 @@
pycodestyle
nose2
-cython>=0.18
+Cython>=0.18
numpy>=1.8
# required for building the docs
diff --git a/setup.py b/setup.py
index 286ec580177748c6011c91abbd45e38bf442aadb..f580b4fc11fc7614c95e5b81192d4f37797fd5fc 100755
--- a/setup.py
+++ b/setup.py
@@ -42,7 +42,8 @@ setup(name='postpic',
# does not work for python 2
'numpy>=1.8', 'numpy>=1.9;python_version<"3.0"',
'scipy', 'future', 'urllib3', 'numexpr',
- 'cython>=0.18', 'functools32;python_version<"3.0"'],
+ 'cython>=0.18', 'functools32;python_version<"3.0"',
+ 'packaging'],
extras_require = {
'h5 reader for openPMD support': ['h5py'],
'sdf support for EPOCH reader': ['sdf'],