Skip to content

Commit 97055b8

Browse files
committed
Implement support for *Python* 3.14, drop support for *Python* 3.10.
1 parent 7f09bc3 commit 97055b8

File tree

8 files changed

+13
-13
lines changed

8 files changed

+13
-13
lines changed

.github/workflows/continuous-integration-quality-unit-tests.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ jobs:
88
strategy:
99
matrix:
1010
os: [macOS-latest, ubuntu-latest, windows-latest]
11-
python-version: ["3.10", 3.11, 3.12, 3.13]
11+
python-version: [3.11, 3.12, 3.13, 3.14]
1212
fail-fast: false
1313
runs-on: ${{ matrix.os }}
1414
steps:

.pre-commit-config.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ repos:
3838
rev: 1.19.1
3939
hooks:
4040
- id: blacken-docs
41-
language_version: python3.10
41+
language_version: python3.11
4242
- repo: https://github.com/pre-commit/mirrors-prettier
4343
rev: "v4.0.0-alpha.8"
4444
hooks:

colour/algebra/tests/test_interpolation.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1306,7 +1306,7 @@ def test_nan__call__(self) -> None:
13061306
try:
13071307
linear_interpolator = LinearInterpolator(case, case)
13081308
linear_interpolator(case[0])
1309-
except ValueError: # noqa: PERF203
1309+
except ValueError:
13101310
pass
13111311

13121312

@@ -1400,7 +1400,7 @@ def test_nan__call__(self) -> None:
14001400
try:
14011401
sprague_interpolator = SpragueInterpolator(case, case)
14021402
sprague_interpolator(case[0]) # pragma: no cover
1403-
except AssertionError: # noqa: PERF203
1403+
except AssertionError:
14041404
pass
14051405

14061406

@@ -1615,7 +1615,7 @@ def test_nan__call__(self) -> None:
16151615
try:
16161616
null_interpolator = NullInterpolator(case, case)
16171617
null_interpolator(case[0])
1618-
except ValueError: # noqa: PERF203
1618+
except ValueError:
16191619
pass
16201620

16211621

colour/hints/__init__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,7 @@
2525
NewType,
2626
NoReturn,
2727
Protocol,
28+
Self,
2829
Set,
2930
SupportsIndex,
3031
TextIO,
@@ -40,7 +41,6 @@
4041

4142
import numpy as np
4243
from numpy.typing import ArrayLike, NDArray
43-
from typing_extensions import Self
4444

4545
__author__ = "Colour Developers"
4646
__copyright__ = "Copyright 2013 Colour Developers"

colour/io/uprtek_sekonic.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -420,7 +420,7 @@ def as_array(a: Any) -> list:
420420
self._metadata[attribute] = method(
421421
value # pyright: ignore
422422
)
423-
except (TypeError, ValueError): # noqa: PERF203
423+
except (TypeError, ValueError):
424424
self._metadata[attribute] = value
425425
else:
426426
break

colour/models/tests/test_cam02_ucs.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -557,5 +557,5 @@ def test_nan_UCS_Luo2006_to_XYZ(self) -> None:
557557
for case in cases:
558558
try:
559559
UCS_Luo2006_to_XYZ(case, COEFFICIENTS_UCS_LUO2006["CAM02-LCD"])
560-
except ValueError as error: # noqa: PERF203
560+
except ValueError as error:
561561
attest("CAM_Specification_CIECAM02" in str(error))

colour/utilities/verbose.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -909,7 +909,7 @@ def _get_package_version(package: str, mapping: Mapping) -> str:
909909
package = mapping.get(package, package) # noqa: PLW2901
910910

911911
environment["Development"][package] = version
912-
except Exception: # pragma: no cover # noqa: BLE001, PERF203, S112
912+
except Exception: # pragma: no cover # noqa: BLE001, S112
913913
continue
914914

915915
environment["Development"].update(ANCILLARY_DEVELOPMENT_PACKAGES)
@@ -922,7 +922,7 @@ def _get_package_version(package: str, mapping: Mapping) -> str:
922922
package = mapping.get(package, package) # noqa: PLW2901
923923

924924
environment["Extras"][package] = version
925-
except Exception: # pragma: no cover # noqa: BLE001, PERF203, S112
925+
except Exception: # pragma: no cover # noqa: BLE001, S112
926926
continue
927927

928928
environment["Extras"].update(ANCILLARY_EXTRAS_PACKAGES)

pyproject.toml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ name = "colour-science"
33
version = "0.4.6"
44
description = "Colour Science for Python"
55
readme = "README.rst"
6-
requires-python = ">=3.10,<3.14"
6+
requires-python = ">=3.11,<3.15"
77
authors = [
88
{ name = "Colour Developers", email = "[email protected]" },
99
]
@@ -54,7 +54,7 @@ optional = [
5454
"imageio>=2,<3",
5555
"matplotlib>=3.9",
5656
"networkx>=3.3,<4",
57-
"opencolorio>=2,<3",
57+
"opencolorio>=2,<3; python_version < '3.14'",
5858
"openimageio>=3,<4",
5959
"pandas>=2.2,<3",
6060
"pydot>=3,<4",
@@ -150,7 +150,7 @@ filterwarnings = [
150150
]
151151

152152
[tool.ruff]
153-
target-version = "py310"
153+
target-version = "py311"
154154
line-length = 88
155155
select = ["ALL"]
156156
ignore = [

0 commit comments

Comments
 (0)