Skip to content

Commit 79355c8

Browse files
authored
Merge pull request #19 from AllenCell/py312_313_support
Py312 313 support
2 parents 309836c + ae8f553 commit 79355c8

File tree

10 files changed

+319
-202
lines changed

10 files changed

+319
-202
lines changed

.github/workflows/build-docs.yml

Lines changed: 27 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -9,26 +9,31 @@ jobs:
99
docs:
1010
runs-on: ubuntu-latest
1111
steps:
12-
- uses: actions/[email protected]
13-
with:
14-
persist-credentials: false
15-
- name: Set up Python
16-
uses: actions/setup-python@0a5c61591373683505ea898e09a3ea4f39ef2b9c
17-
with:
18-
python-version: 3.9
19-
- name: Install Dependencies
20-
run: |
21-
pip install --upgrade pip
22-
pip install .[dev]
23-
- name: Generate Docs
24-
run: |
25-
make gen-docs
26-
touch docs/_build/html/.nojekyll
27-
- name: Publish Docs
28-
uses: JamesIves/[email protected]
29-
with:
30-
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
31-
BASE_BRANCH: main # The branch the action should deploy from.
32-
BRANCH: gh-pages # The branch the action should deploy to.
33-
FOLDER: docs/_build/html/ # The folder the action should deploy.
12+
- name: Checkout Repository
13+
uses: actions/checkout@v3
14+
with:
15+
persist-credentials: false
3416

17+
- name: Set up Python
18+
uses: actions/setup-python@v4
19+
with:
20+
python-version: '3.12'
21+
cache: 'pip'
22+
23+
- name: Install Dependencies
24+
run: |
25+
python -m pip install --upgrade pip
26+
pip install .[dev]
27+
28+
- name: Generate Docs
29+
run: |
30+
make gen-docs
31+
touch docs/_build/html/.nojekyll
32+
33+
- name: Publish Docs
34+
uses: JamesIves/[email protected]
35+
with:
36+
branch: gh-pages
37+
folder: docs/_build/html/
38+
token: ${{ secrets.GITHUB_TOKEN }}
39+
clean: true

.github/workflows/build-main.yml

Lines changed: 67 additions & 48 deletions
Original file line numberDiff line numberDiff line change
@@ -15,65 +15,84 @@ jobs:
1515
runs-on: ${{ matrix.os }}
1616
strategy:
1717
matrix:
18-
python-version: ["3.9", "3.10", "3.11"]
18+
python-version: ["3.9", "3.10", "3.11", "3.12"]
1919
os: [ubuntu-latest, windows-latest, macOS-latest]
2020

2121
steps:
22-
- uses: actions/checkout@v1
23-
- name: Set up Python ${{ matrix.python-version }}
24-
uses: actions/setup-python@0a5c61591373683505ea898e09a3ea4f39ef2b9c
25-
with:
26-
python-version: ${{ matrix.python-version }}
27-
- name: Install Dependencies
28-
run: |
29-
python -m pip install --upgrade pip
30-
pip install .[test]
31-
- name: Test with pytest
32-
run: |
33-
pytest --cov-report xml --cov=aicsshparam aicsshparam/tests/
34-
- name: Upload codecov
35-
uses: codecov/codecov-action@v1
22+
- uses: actions/checkout@v3
23+
24+
# Set up Python using setup-python
25+
- name: Set up Python ${{ matrix.python-version }}
26+
uses: actions/setup-python@v4
27+
with:
28+
python-version: ${{ matrix.python-version }}
29+
30+
# Install Python dependencies
31+
- name: Install Dependencies
32+
run: |
33+
python -m pip install --upgrade pip
34+
pip install .[test]
35+
36+
# Run Pytest with coverage
37+
- name: Test with pytest
38+
run: |
39+
pytest --cov-report xml --cov=aicsshparam aicsshparam/tests/
40+
41+
# Upload Code Coverage
42+
- name: Upload Code Coverage
43+
uses: codecov/codecov-action@v3
3644

3745
lint:
3846
runs-on: ubuntu-latest
47+
strategy:
48+
matrix:
49+
python-version: ["3.9", "3.10", "3.11", "3.12"]
3950

4051
steps:
41-
- uses: actions/checkout@v1
42-
- name: Set up Python
43-
uses: actions/setup-python@0a5c61591373683505ea898e09a3ea4f39ef2b9c
44-
with:
45-
python-version: 3.9
46-
- name: Install Dependencies
47-
run: |
48-
python -m pip install --upgrade pip
49-
pip install .[test]
50-
- name: Lint with flake8
51-
run: |
52-
flake8 aicsshparam --count --verbose --show-source --statistics
53-
- name: Check with black
54-
run: |
55-
black --check aicsshparam
52+
- uses: actions/checkout@v3
53+
54+
- name: Set up Python ${{ matrix.python-version }}
55+
uses: actions/setup-python@v4
56+
with:
57+
python-version: ${{ matrix.python-version }}
58+
59+
- name: Install Dependencies
60+
run: |
61+
python -m pip install --upgrade pip
62+
pip install .[test]
63+
64+
- name: Lint with Flake8
65+
run: |
66+
flake8 aicsshparam --count --verbose --show-source --statistics
67+
68+
- name: Check with Black
69+
run: |
70+
black --check aicsshparam
5671
5772
publish:
58-
if: "contains(github.event.head_commit.message, 'Bump version')"
73+
if: contains(github.event.head_commit.message, 'Bump version')
5974
needs: [test, lint]
6075
runs-on: ubuntu-latest
6176

6277
steps:
63-
- uses: actions/checkout@v1
64-
- name: Set up Python
65-
uses: actions/setup-python@0a5c61591373683505ea898e09a3ea4f39ef2b9c
66-
with:
67-
python-version: 3.9
68-
- name: Install Dependencies
69-
run: |
70-
python -m pip install --upgrade pip
71-
pip install setuptools wheel
72-
- name: Build Package
73-
run: |
74-
python setup.py sdist bdist_wheel
75-
- name: Publish to PyPI
76-
uses: pypa/gh-action-pypi-publish@master
77-
with:
78-
user: __token__
79-
password: ${{ secrets.PYPI_TOKEN }}
78+
- uses: actions/checkout@v3
79+
80+
- name: Set up Python
81+
uses: actions/setup-python@v4
82+
with:
83+
python-version: '3.12'
84+
85+
- name: Install Dependencies
86+
run: |
87+
python -m pip install --upgrade pip
88+
pip install setuptools wheel
89+
90+
- name: Build Package
91+
run: |
92+
python setup.py sdist bdist_wheel
93+
94+
- name: Publish to PyPI
95+
uses: pypa/[email protected]
96+
with:
97+
user: __token__
98+
password: ${{ secrets.PYPI_TOKEN }}

.github/workflows/test-and-lint.yml

Lines changed: 48 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -7,41 +7,59 @@ jobs:
77
runs-on: ${{ matrix.os }}
88
strategy:
99
matrix:
10-
python-version: ["3.9", "3.10", "3.11"]
10+
python-version: ["3.9", "3.10", "3.11", "3.12"]
1111
os: [ubuntu-latest, windows-latest, macOS-latest]
1212

1313
steps:
14-
- uses: actions/checkout@v1
15-
- name: Set up Python ${{ matrix.python-version }}
16-
uses: actions/setup-python@0a5c61591373683505ea898e09a3ea4f39ef2b9c
17-
with:
18-
python-version: ${{ matrix.python-version }}
19-
- name: Install Dependencies
20-
run: |
21-
python -m pip install --upgrade pip
22-
pip install .[test]
23-
- name: Test with pytest
24-
run: |
25-
pytest aicsshparam/tests/
26-
- name: Upload codecov
27-
uses: codecov/codecov-action@v1
14+
- name: Checkout Repository
15+
uses: actions/checkout@v3
16+
17+
# Set up Python using setup-python
18+
- name: Set up Python ${{ matrix.python-version }}
19+
uses: actions/setup-python@v4
20+
with:
21+
python-version: ${{ matrix.python-version }}
22+
cache: 'pip'
23+
24+
- name: Install Dependencies
25+
run: |
26+
python -m pip install --upgrade pip
27+
pip install .[test]
28+
29+
- name: Test with pytest
30+
run: |
31+
pytest aicsshparam/tests/
32+
33+
- name: Upload Code Coverage
34+
uses: codecov/codecov-action@v3
35+
with:
36+
token: ${{ secrets.CODECOV_TOKEN }}
2837

2938
lint:
3039
runs-on: ubuntu-latest
40+
strategy:
41+
matrix:
42+
python-version: ["3.9", "3.10", "3.11", "3.12"]
3143

3244
steps:
33-
- uses: actions/checkout@v1
34-
- name: Set up Python
35-
uses: actions/setup-python@0a5c61591373683505ea898e09a3ea4f39ef2b9c
36-
with:
37-
python-version: 3.9
38-
- name: Install Dependencies
39-
run: |
40-
python -m pip install --upgrade pip
41-
pip install .[test]
42-
- name: Lint with flake8
43-
run: |
44-
flake8 aicsshparam --count --verbose --show-source --statistics
45-
- name: Check with black
46-
run: |
47-
black --check aicsshparam
45+
- name: Checkout Repository
46+
uses: actions/checkout@v3
47+
48+
- name: Set up Python ${{ matrix.python-version }}
49+
uses: actions/setup-python@v4
50+
with:
51+
python-version: ${{ matrix.python-version }}
52+
cache: 'pip'
53+
54+
- name: Install Dependencies
55+
run: |
56+
python -m pip install --upgrade pip
57+
pip install .[test]
58+
59+
- name: Lint with Flake8
60+
run: |
61+
flake8 aicsshparam --count --verbose --show-source --statistics
62+
63+
- name: Check with Black
64+
run: |
65+
black --check aicsshparam

CONTRIBUTING.md

Lines changed: 22 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -51,13 +51,30 @@ Ready to contribute? Here's how to set up `aicsshparam` for local development.
5151
## Deploying
5252
5353
A reminder for the maintainers on how to deploy.
54-
Make sure all your changes are committed.
55-
Then run:
5654
55+
1. **Ensure all changes are committed.**
56+
Refer to [bump2version on PyPI](https://pypi.org/project/bump2version/) for more details on versioning.
57+
58+
2. **Bump the version number.**
59+
Run one of the following commands depending on the type of version update:
60+
```bash
61+
bump2version major # for major releases with breaking changes
62+
bump2version minor # for minor releases with new features
63+
bump2version patch # for patch releases with bug fixes
64+
```
65+
66+
3. **Push the changes and tags to the repository.**
67+
```bash
68+
git push
69+
git push --tags
70+
```
71+
72+
---
73+
74+
**Note:**
75+
Sometimes, you might encounter situations where there are uncommitted changes or modifications in your working directory that you intend to include in the release. In such cases, you can use the `--allow-dirty` flag with `bump2version` to permit version bumping even when the working directory isn't clean:
5776
```bash
58-
bump2version patch # possible: major / minor / patch
59-
git push
60-
git push --tags
77+
bump2version patch --allow-dirty
6178
```
6279

6380
This will release a new package version on Git + GitHub and publish to PyPI.

README.md

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,21 @@
99

1010
## Installation:
1111

12+
## Build Dependencies for Python 3.13.*
13+
14+
If you are using Python 3.13.*, you will need to install the following build dependencies:
15+
16+
- **fftw**
17+
- **openblas**
18+
- **cmake**
19+
- **pkg-config**
20+
21+
One convenient way to install these dependencies is by using Conda. You can run the following command:
22+
23+
```bash
24+
conda install -c conda-forge fftw openblas cmake pkg-config
25+
```
26+
1227
**Stable Release**: `pip install aicsshparam`
1328

1429
**Build from source to make customization**:

aicsshparam/__init__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
__email__ = "[email protected]"
77
# Do not edit this string manually, always use bumpversion
88
# Details in CONTRIBUTING.md
9-
__version__ = "0.1.10"
9+
__version__ = "0.1.11"
1010

1111

1212
def get_module_version():

0 commit comments

Comments
 (0)