Skip to content

Commit b910153

Browse files
committed
Merge branch 'main' of github.com:sunpy/sunkit-image into pr/207
2 parents 6f72952 + 37d256f commit b910153

File tree

16 files changed

+59
-66
lines changed

16 files changed

+59
-66
lines changed

.cruft.json

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"template": "https://github.com/sunpy/package-template",
3-
"commit": "88a0a31eadf2be84895e32ffd792768c2863f7ca",
3+
"commit": "bea8060eef60df35f7df61d9db1d56b838bda01a",
44
"checkout": null,
55
"context": {
66
"cookiecutter": {
@@ -17,7 +17,7 @@
1717
"changelog_url": "https://docs.sunpy.org/projects/sunkit-image/en/stable/whatsnew/changelog.html",
1818
"issue_tracker_url": "https://github.com/sunpy/sunkit-image/issues",
1919
"license": "BSD 2-Clause",
20-
"minimum_python_version": "3.10",
20+
"minimum_python_version": "3.12",
2121
"use_compiled_extensions": "n",
2222
"enable_dynamic_dev_versions": "y",
2323
"include_example_code": "n",
@@ -32,7 +32,7 @@
3232
".github/workflows/sub_package_update.yml"
3333
],
3434
"_template": "https://github.com/sunpy/package-template",
35-
"_commit": "88a0a31eadf2be84895e32ffd792768c2863f7ca"
35+
"_commit": "bea8060eef60df35f7df61d9db1d56b838bda01a"
3636
}
3737
},
3838
"directory": null

.github/workflows/ci.yml

Lines changed: 15 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -42,10 +42,10 @@ jobs:
4242
sdist_verify:
4343
runs-on: ubuntu-latest
4444
steps:
45-
- uses: actions/checkout@v4
46-
- uses: actions/setup-python@v5
45+
- uses: actions/checkout@v5
46+
- uses: actions/setup-python@v6
4747
with:
48-
python-version: '3.12'
48+
python-version: '3.13'
4949
- run: python -m pip install -U --user build
5050
- run: python -m build . --sdist
5151
- run: python -m pip install -U --user twine
@@ -60,18 +60,19 @@ jobs:
6060
toxdeps: tox-pypi-filter
6161
posargs: -n auto
6262
envs: |
63-
- windows: py311
63+
- linux: py314
64+
- windows: py312
6465
- macos: py312
65-
- linux: py310-oldestdeps
66-
- linux: py313-devdeps
66+
- linux: py312-oldestdeps
67+
- linux: py314-devdeps
6768
secrets:
6869
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
6970

7071
docs:
7172
needs: [core]
7273
uses: OpenAstronomy/github-actions-workflows/.github/workflows/tox.yml@v2
7374
with:
74-
default_python: '3.12'
75+
default_python: '3.13'
7576
submodules: false
7677
pytest: false
7778
toxdeps: tox-pypi-filter
@@ -86,48 +87,35 @@ jobs:
8687
needs: [test]
8788
uses: OpenAstronomy/github-actions-workflows/.github/workflows/tox.yml@v2
8889
with:
89-
default_python: '3.12'
90+
default_python: '3.13'
9091
submodules: false
9192
coverage: codecov
9293
toxdeps: tox-pypi-filter
9394
posargs: -n 1
9495
envs: |
95-
- linux: py312-online
96-
secrets:
97-
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
98-
99-
devdeps:
100-
needs: [test]
101-
uses: OpenAstronomy/github-actions-workflows/.github/workflows/tox.yml@main
102-
with:
103-
submodules: false
104-
coverage: codecov
105-
toxdeps: tox-pypi-filter
106-
posargs: -n auto
107-
envs: |
108-
- linux: py312-devdeps
96+
- linux: py313-online
10997
secrets:
11098
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
11199

112100
conda:
113101
needs: [online]
114102
runs-on: ubuntu-latest
115103
steps:
116-
- uses: actions/checkout@v4
104+
- uses: actions/checkout@v5
117105
with:
118106
fetch-depth: 0
119107
lfs: true
120108
- uses: conda-incubator/setup-miniconda@v3
121109
with:
122-
installer-url: https://github.com/conda-forge/miniforge/releases/download/24.3.0-0/Miniforge3-24.3.0-0-Linux-x86_64.sh
123-
python-version: "3.12"
110+
installer-url: https://github.com/conda-forge/miniforge/releases/download/25.3.1-0/Miniforge3-25.3.1-0-Linux-x86_64.sh
111+
python-version: "3.13"
124112
activate-environment: sunkit_image_test
125113
environment-file: sunkit-test-env.yaml
126114
- name: Run tests
127115
shell: bash -el {0}
128116
run: |
129117
conda list
130-
tox -e py312
118+
tox -e py313
131119
- uses: codecov/codecov-action@v5
132120
with:
133121
token: ${{ secrets.CODECOV_TOKEN }}
@@ -145,7 +133,7 @@ jobs:
145133
needs: [test, docs]
146134
uses: OpenAstronomy/github-actions-workflows/.github/workflows/publish_pure_python.yml@v2
147135
with:
148-
python-version: '3.12'
136+
python-version: '3.13'
149137
test_extras: 'tests'
150138
test_command: 'pytest -p no:warnings --doctest-rst -m "not mpl_image_compare" --pyargs sunkit_image'
151139
submodules: false

.github/workflows/sub_package_update.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,9 +22,9 @@ jobs:
2222
strategy:
2323
fail-fast: true
2424
steps:
25-
- uses: actions/checkout@v4
25+
- uses: actions/checkout@v5
2626

27-
- uses: actions/setup-python@v5
27+
- uses: actions/setup-python@v6
2828
with:
2929
python-version: "3.11"
3030

.pre-commit-config.yaml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,16 @@
11
repos:
22
- repo: https://github.com/astral-sh/ruff-pre-commit
3-
rev: "v0.12.1"
3+
rev: "v0.13.3"
44
hooks:
55
- id: ruff
66
args: ["--fix", "--unsafe-fixes"]
77
- repo: https://github.com/PyCQA/isort
8-
rev: 6.0.1
8+
rev: 6.1.0
99
hooks:
1010
- id: isort
1111
exclude: ".*(.fits|.fts|.fit|.header|.txt|tca.*|extern.*|sunkit_image/extern)$"
1212
- repo: https://github.com/pre-commit/pre-commit-hooks
13-
rev: v5.0.0
13+
rev: v6.0.0
1414
hooks:
1515
- id: check-ast
1616
- id: check-case-conflict
@@ -35,7 +35,7 @@ repos:
3535
hooks:
3636
- id: typos
3737
- repo: https://github.com/pre-commit/mirrors-mypy
38-
rev: "v1.16.1"
38+
rev: "v1.18.2"
3939
hooks:
4040
- id: mypy
4141
additional_dependencies: ["types-setuptools"]

.ruff.toml

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -35,8 +35,6 @@ extend-ignore = [
3535
"A005", # Module `trace` shadows a Python standard-library module
3636
# pycodestyle (E, W)
3737
"E501", # ignore line length will use a formatter instead
38-
# pyupgrade (UP)
39-
"UP038", # Use | in isinstance - not compatible with models and is slower
4038
# pytest (PT)
4139
"PT001", # Always use pytest.fixture()
4240
"PT023", # Always use () on pytest decorators

changelog/290.breaking.rst

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
Increased the minimum required versions:
2+
3+
- Python 3.12 (from 3.10)
4+
- Matplotlib 3.8.0 (from 3.5.0)
5+
- sunpy 7.0.0 (from 6.0.0)
6+
- NumPy 1.26.0 (from 1.23.5)
7+
- Astropy 6.1.0 (from 5.3.0)
8+
- SciPy 1.11.0 (from 1.10.1)

docs/conf.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -80,8 +80,7 @@
8080
exclude_patterns = ["_build", "Thumbs.db", ".DS_Store"]
8181

8282
# The suffix(es) of source filenames.
83-
# You can specify multiple suffix as a list of string:
84-
source_suffix = ".rst"
83+
source_suffix = {".rst": "restructuredtext"}
8584

8685
# The master toctree document.
8786
master_doc = "index"

pyproject.toml

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ build-backend = "setuptools.build_meta"
1010
name = "sunkit_image"
1111
dynamic = ["version"]
1212
description = "An image processing toolbox for Solar Physics."
13-
requires-python = ">=3.10"
13+
requires-python = ">=3.12"
1414
readme = { file = "README.rst", content-type = "text/x-rst" }
1515
license = { file = "LICENSE.txt" }
1616
keywords = ["solar physics", "solar", "science", "image analysis"]
@@ -31,12 +31,12 @@ classifiers = [
3131
"Topic :: Scientific/Engineering :: Physics",
3232
]
3333
dependencies = [
34-
"astropy>=5.3.0",
35-
"numpy>=1.23.5",
36-
"matplotlib>=3.5.0",
37-
"scipy>=1.10.1",
34+
"astropy>=6.1.0",
35+
"numpy>=1.26.0",
36+
"matplotlib>=3.8.0",
37+
"scipy>=1.11.0",
3838
"scikit-image>=0.20.0",
39-
"sunpy[map]>=6.0.0",
39+
"sunpy[map]>=7.0.0",
4040
]
4141

4242
[project.optional-dependencies]
@@ -49,7 +49,7 @@ tests = [
4949
"pytest-astropy",
5050
"pytest-mpl",
5151
"pytest-xdist",
52-
"sunpy[data,net]>=6.0.0",
52+
"sunpy[data,net]>=7.0.0",
5353
]
5454
docs = [
5555
"sphinx",
@@ -63,7 +63,7 @@ docs = [
6363
"matplotlib",
6464
"sphinx-design",
6565
"sphinx-gallery",
66-
"sunpy[data,net]>=6.0.0",
66+
"sunpy[data,net]>=7.0.0",
6767
]
6868
dev = ["sunkit_image[all,tests,docs]"]
6969

sunkit_image/coalignment/tests/test_coalignment.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -132,7 +132,7 @@ def test_unsupported_affine_parameters(incorrect_pointing_cutout_map, aia171_tes
132132
rotation_matrix=2*np.eye(2),
133133
translation=[0,0],
134134
)
135-
with pytest.raises(NotImplementedError, match='Changes to the rotation metadata are currently not supported.'):
135+
with pytest.raises(NotImplementedError, match=r"Changes to the rotation metadata are currently not supported."):
136136
_ = _update_fits_wcs_metadata(incorrect_pointing_cutout_map,
137137
aia171_test_map,
138138
affine_rot)
@@ -141,7 +141,7 @@ def test_unsupported_affine_parameters(incorrect_pointing_cutout_map, aia171_tes
141141
rotation_matrix=np.eye(2),
142142
translation=[0,0],
143143
)
144-
with pytest.raises(NotImplementedError, match='Changes to the pixel scale metadata are currently not supported.'):
144+
with pytest.raises(NotImplementedError, match=r"Changes to the pixel scale metadata are currently not supported."):
145145
_ = _update_fits_wcs_metadata(incorrect_pointing_cutout_map,
146146
aia171_test_map,
147147
affine_scale)

sunkit_image/coalignment/tests/test_match_template.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -39,11 +39,11 @@ def test_get_correlation_shifts():
3939

4040
# Input array is too big in either direction
4141
test_array = np.zeros((4, 3))
42-
with pytest.raises(ValueError, match="Input array dimension should not be greater than 3 in any dimension."):
42+
with pytest.raises(ValueError, match=r"Input array dimension should not be greater than 3 in any dimension."):
4343
_get_correlation_shifts(test_array)
4444

4545
test_array = np.zeros((3, 4))
46-
with pytest.raises(ValueError, match="Input array dimension should not be greater than 3 in any dimension."):
46+
with pytest.raises(ValueError, match=r"Input array dimension should not be greater than 3 in any dimension."):
4747
_get_correlation_shifts(test_array)
4848

4949

0 commit comments

Comments
 (0)