Skip to content

Commit

Permalink
Update supported Python versions (#22)
Browse files Browse the repository at this point in the history
* Update actions/download-artifact to v4 (#10)

* Update actions/download-artifact to v4

* Bumped pypa/gh-action-pypi-publish to v1.8.0

* Use latest minor version of pypi upload action (#11)

* pin specific patch version for pypi upload action (#12)

* reuse pypi upload action (#13)

* Update pypi_upload step in workflow

* pass secret PyPI upload key as input to upload_pypi step

* use v2 for all reusable NIU actions

including the update upload_pypi one.

* run CI on both types of Mac (#16)

* run CI on both types of Mac

* Fix link in readme

* [pre-commit.ci] pre-commit autoupdate (#18)

updates:
- [github.com/pre-commit/pre-commit-hooks: v4.4.0 → v4.6.0](pre-commit/pre-commit-hooks@v4.4.0...v4.6.0)
- https://github.com/charliermarsh/ruff-pre-commithttps://github.com/astral-sh/ruff-pre-commit
- [github.com/astral-sh/ruff-pre-commit: v0.0.292 → v0.5.0](astral-sh/ruff-pre-commit@v0.0.292...v0.5.0)
- [github.com/psf/black: 23.9.1 → 24.4.2](psf/black@23.9.1...24.4.2)
- [github.com/pre-commit/mirrors-mypy: v1.5.1 → v1.10.1](pre-commit/mirrors-mypy@v1.5.1...v1.10.1)

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>

* Add a standardised contact section to the readme

* [pre-commit.ci] pre-commit autoupdate

updates:
- [github.com/astral-sh/ruff-pre-commit: v0.5.0 → v0.5.6](astral-sh/ruff-pre-commit@v0.5.0...v0.5.6)
- [github.com/psf/black: 24.4.2 → 24.8.0](psf/black@24.4.2...24.8.0)
- [github.com/pre-commit/mirrors-mypy: v1.10.1 → v1.11.1](pre-commit/mirrors-mypy@v1.10.1...v1.11.1)

* move toml to 3.12

* move actions to 3.12

---------

Co-authored-by: viktorpm <[email protected]>
Co-authored-by: Niko Sirmpilatze <[email protected]>
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Adam Tyson <[email protected]>
  • Loading branch information
5 people authored Aug 15, 2024
1 parent f082153 commit 1b8a10e
Show file tree
Hide file tree
Showing 4 changed files with 23 additions and 29 deletions.
21 changes: 9 additions & 12 deletions .github/workflows/test_and_deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,14 +27,16 @@ jobs:
strategy:
matrix:
# Run all supported Python versions on linux
python-version: ["3.9", "3.10", "3.11"]
python-version: ["3.10", "3.11", "3.12"]
os: [ubuntu-latest]
# Include one windows and macos run
# Include one windows and ARM/Intel macos run
include:
- os: macos-latest
python-version: "3.10"
- os: macos-13 # Intel Mac
python-version: "3.12"
- os: macos-latest # ARM Mac
python-version: "3.12"
- os: windows-latest
python-version: "3.10"
python-version: "3.11"

steps:
# Run tests
Expand All @@ -56,11 +58,6 @@ jobs:
needs: [build_sdist_wheels]
runs-on: ubuntu-latest
steps:
- uses: actions/download-artifact@v3
- uses: neuroinformatics-unit/actions/upload_pypi@v2
with:
name: artifact
path: dist
- uses: pypa/[email protected]
with:
user: __token__
password: ${{ secrets.BTB_UPLOAD_API_KEY }}
secret-pypi-key: ${{ secrets.BTB_UPLOAD_API_KEY }}
10 changes: 5 additions & 5 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ ci:
autoupdate_schedule: monthly
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v4.4.0
rev: v4.6.0
hooks:
- id: check-docstring-first
- id: check-executables-have-shebangs
Expand All @@ -15,16 +15,16 @@ repos:
args: [--fix=lf]
- id: requirements-txt-fixer
- id: trailing-whitespace
- repo: https://github.com/charliermarsh/ruff-pre-commit
rev: v0.0.292
- repo: https://github.com/astral-sh/ruff-pre-commit
rev: v0.5.6
hooks:
- id: ruff
- repo: https://github.com/psf/black
rev: 23.9.1
rev: 24.8.0
hooks:
- id: black
- repo: https://github.com/pre-commit/mirrors-mypy
rev: v1.5.1
rev: v1.11.1
hooks:
- id: mypy
additional_dependencies:
Expand Down
5 changes: 4 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ Build unbiased anatomical templates from individual images
`brainglobe-template-builder` aims to:
- Offer an intuitive Python interface to the [optimised ANTs template construction pipeline](#template-construction-with-ants).
- Support 3D volumetric microscopy images, such as STPT and LSM.
- Generate templates compatible with the [BrainGlobe ecosystem](https://brainglobe.info/), especially the [BrainGlobe Atlas API](https://brainglobe.info/documentation/bg-atlasapi/index.html).
- Generate templates compatible with the [BrainGlobe ecosystem](https://brainglobe.info/), especially the [BrainGlobe Atlas API](https://brainglobe.info/documentation/brainglobe-atlasapi/index.html).

> **Warning**
> - Early development phase. Stay tuned
Expand Down Expand Up @@ -107,6 +107,9 @@ ANTs includes a template construction piepline - implemented in the [antsMultiva

An [optimsed implementation of the above pipeline](https://github.com/CoBrALab/optimized_antsMultivariateTemplateConstruction/tree/master), developed by the [CoBra lab](https://www.cobralab.ca/), lies at the core of the `brainglobe-template-builder`'s functionality.

## Seeking help or contributing
We are always happy to help users of our tools, and welcome any contributions. If you would like to get in contact with us for any reason, please see the [contact page of our website](https://brainglobe.info/contact.html).

## License
⚖️ [BSD 3-Clause](https://opensource.org/license/bsd-3-clause/)

Expand Down
16 changes: 5 additions & 11 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ name = "brainglobe-template-builder"
authors = [{ name = "Niko Sirmpilatze", email = "[email protected]" }]
description = "Build unbiased anatomical templates from individual images"
readme = "README.md"
requires-python = ">=3.9.0"
requires-python = ">=3.10.0"
dynamic = ["version"]

license = { text = "BSD-3-Clause" }
Expand All @@ -12,9 +12,9 @@ classifiers = [
"Development Status :: 2 - Pre-Alpha",
"Programming Language :: Python",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.9",
"Programming Language :: Python :: 3.10",
"Programming Language :: Python :: 3.11",
"Programming Language :: Python :: 3.12",
"Operating System :: OS Independent",
"License :: OSI Approved :: BSD License",
]
Expand Down Expand Up @@ -65,7 +65,7 @@ exclude = ["tests", "docs*"]
addopts = "--cov=brainglobe_template_builder"

[tool.black]
target-version = ['py39', 'py310', 'py311']
target-version = ['py310', 'py311', 'py312']
skip-string-normalization = false
line-length = 79

Expand All @@ -90,23 +90,17 @@ exclude = ["__init__.py", "build", ".eggs", "scripts"]
select = ["I", "E", "F"]
fix = true

[tool.cibuildwheel]
build = "cp39-* cp310-* cp311-*"

[tool.cibuildwheel.macos]
archs = ["x86_64", "arm64"]

[tool.tox]
legacy_tox_ini = """
[tox]
envlist = py{39,310,311}
envlist = py{310,311,312}
isolated_build = True
[gh-actions]
python =
3.9: py39
3.10: py310
3.11: py311
3.12: py312
[testenv]
extras =
Expand Down

0 comments on commit 1b8a10e

Please sign in to comment.