Skip to content

Commit 56538af

Browse files
committed
Update workflows
1 parent af923e5 commit 56538af

File tree

5 files changed

+43
-24
lines changed

5 files changed

+43
-24
lines changed

.github/workflows/docs.yml

Lines changed: 7 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -17,27 +17,24 @@ jobs:
1717
docs:
1818
name: Documentation
1919
runs-on: ubuntu-latest
20-
container:
21-
image: cupy/cupy:v13.4.0
2220

2321
steps:
2422
- uses: actions/checkout@v3
2523

2624
- name: Clean previous builds
2725
run: rm -rf build dist *.egg-info
2826

29-
- name: Set up git
30-
run: apt-get update && apt-get install git -y
31-
3227
- name: Install system dependencies
3328
run: |
34-
apt-get update && apt-get install -y python3-venv python3-pip
29+
sudo apt-get update
30+
sudo apt-get install -y python3.12 python3.12-venv python3-pip git
3531
36-
- name: Install additional dependencies
32+
- name: Create virtual environment and install package
3733
run: |
38-
python3.10 -m venv venv
34+
python3.12 -m venv venv
3935
source venv/bin/activate
40-
python3.10 -m pip install --no-cache-dir .
36+
python3.12 -m pip install --upgrade pip
37+
python3.12 -m pip install --no-cache-dir .
4138
shell: bash -e {0}
4239

4340
- name: Generate documentation
@@ -46,7 +43,7 @@ jobs:
4643
cd docs
4744
make html
4845
shell: bash -e {0}
49-
46+
5047
- name: Deploy
5148
if: success()
5249
uses: peaceiris/actions-gh-pages@v3

.github/workflows/tests.yml

Lines changed: 19 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -16,35 +16,42 @@ on:
1616

1717
jobs:
1818
test:
19-
name: Testing using pytest
19+
name: Testing on Python ${{ matrix.python-version }}
2020
runs-on: ubuntu-latest
21-
container:
22-
image: cupy/cupy:v13.4.0
21+
22+
strategy:
23+
matrix:
24+
python-version: ['3.10', '3.11', '3.12']
2325

2426
steps:
2527
- uses: actions/checkout@v3
2628

29+
- name: Set up Python ${{ matrix.python-version }}
30+
uses: actions/setup-python@v5
31+
with:
32+
python-version: ${{ matrix.python-version }}
33+
2734
- name: Clean previous builds
2835
run: rm -rf build dist *.egg-info
2936

3037
- name: Install system dependencies
3138
run: |
32-
apt-get update && apt-get install -y python3.10-venv python3-pip cmake
39+
sudo apt-get update
40+
sudo apt-get install -y cmake python${{ matrix.python-version }}-venv python3-pip
3341
34-
- name: Install additional dependencies
42+
- name: Create virtualenv and install Python dependencies
3543
run: |
36-
python3.10 -m venv venv
44+
python -m venv venv
3745
source venv/bin/activate
38-
python3.10 -m pip install --no-cache-dir .
46+
python -m pip install --upgrade pip
47+
python -m pip install --no-cache-dir .
3948
shell: bash -e {0}
4049

4150
- name: Test with pytest
4251
run: |
4352
source venv/bin/activate
4453
mkdir -p build
4554
cmake -B build -S .
46-
cd build
47-
make
48-
cd ..
49-
python3.10 -m pytest
50-
shell: bash -e {0}
55+
cmake --build build
56+
python -m pytest
57+
shell: bash -e {0}

README.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,3 +12,5 @@ TO DO:
1212
4) Accuracy vs efficiency
1313
5) Script to run on Ulysses
1414
6) Add missing tests
15+
7) Possibly delete eigenvalues\_np and so on, which I inserted because I thought it was not going to be necessary to compute the eigenvectors, making these wrappers useless
16+
8) Write missing documentation

docs/pyclassify.rst

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,4 +17,13 @@ Submodule: utils
1717
.. automodule:: pyclassify.utils
1818
:members:
1919
:undoc-members:
20-
:show-inheritance:
20+
:show-inheritance:
21+
22+
Submodule: helpers_secular
23+
================
24+
25+
.. automodule:: pyclassify.helpers_secular
26+
:members:
27+
:undoc-members:
28+
:show-inheritance:
29+

setup.py

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,11 @@ def build_extension(self, ext):
4848
ext_modules=[CMakeExtension("pyclassify.QR_cpp")],
4949
packages=find_packages(where="src/"),
5050
package_dir={"": "src/"},
51-
package_data={"pyclassify": ["QR_cpp.cpython-312-x86_64-linux-gnu.so"]},
51+
package_data={
52+
"pyclassify": [
53+
f"QR_cpp.cpython-{sys.version_info[0]}{sys.version_info[1]}-x86_64-linux-gnu.so"
54+
]
55+
},
5256
include_package_data=True,
5357
cmdclass={"build_ext": CMakeBuild},
5458
zip_safe=False,

0 commit comments

Comments
 (0)