From 2a4f0024834fd6c8415089a941671468090d808c Mon Sep 17 00:00:00 2001 From: Tomas Pereira de Vasconcelos Date: Sun, 12 Oct 2025 01:01:57 +1100 Subject: [PATCH 1/4] Revert "Revert CI checks for Python 3.14" This reverts commit a83fdcbe326fce1fff13cd59803f764a98881aad. --- .github/workflows/ci.yml | 2 +- docs/reference/changelog.md | 1 + pyproject.toml | 2 +- 3 files changed, 3 insertions(+), 2 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 26347ccc..e03bff2d 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -51,7 +51,7 @@ jobs: - "3.11" - "3.12" - "3.13" - #- "3.14" + - "3.14" os: - ubuntu-latest # There shouldn't be any behavior differences between OSes, diff --git a/docs/reference/changelog.md b/docs/reference/changelog.md index e4444331..5f065e9e 100644 --- a/docs/reference/changelog.md +++ b/docs/reference/changelog.md @@ -5,6 +5,7 @@ This document outlines the list of changes to ridgeplot between each release. Fo Unreleased changes ------------------ +- Add support for Python 3.14, in accordance with the official Python support policy[^1] ({gh-pr}`345`) - Dropped support for Python 3.9, in accordance with the official Python support policy[^1] ({gh-pr}`345`) - Bump project classification from Pre-Alpha to Alpha ({gh-pr}`336`) diff --git a/pyproject.toml b/pyproject.toml index 17204a18..7264cd54 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -26,7 +26,7 @@ classifiers = [ "Programming Language :: Python :: 3.11", "Programming Language :: Python :: 3.12", "Programming Language :: Python :: 3.13", - #"Programming Language :: Python :: 3.14", + "Programming Language :: Python :: 3.14", "Programming Language :: Python :: Implementation :: CPython", "Topic :: Software Development", "Topic :: Scientific/Engineering", From d80d1f40a19de156a98b008c3b71d2b573df9af8 Mon Sep 17 00:00:00 2001 From: Tomas Pereira de Vasconcelos Date: Sun, 12 Oct 2025 01:03:36 +1100 Subject: [PATCH 2/4] Update changelog.md Signed-off-by: Tomas Pereira de Vasconcelos --- docs/reference/changelog.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/reference/changelog.md b/docs/reference/changelog.md index 5f065e9e..fa7c5194 100644 --- a/docs/reference/changelog.md +++ b/docs/reference/changelog.md @@ -5,7 +5,7 @@ This document outlines the list of changes to ridgeplot between each release. Fo Unreleased changes ------------------ -- Add support for Python 3.14, in accordance with the official Python support policy[^1] ({gh-pr}`345`) +- Add support for Python 3.14, in accordance with the official Python support policy[^1] ({gh-pr}`346`) - Dropped support for Python 3.9, in accordance with the official Python support policy[^1] ({gh-pr}`345`) - Bump project classification from Pre-Alpha to Alpha ({gh-pr}`336`) From ddecf3dd56d9317a42577309bcd4f4c67d53dff1 Mon Sep 17 00:00:00 2001 From: Tomas Pereira de Vasconcelos Date: Fri, 26 Dec 2025 21:18:18 +0800 Subject: [PATCH 3/4] Update expected error message to support Python 3.14 Signed-off-by: Tomas Pereira de Vasconcelos --- tests/unit/test_utils.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/unit/test_utils.py b/tests/unit/test_utils.py index 6e70a845..cd070dca 100644 --- a/tests/unit/test_utils.py +++ b/tests/unit/test_utils.py @@ -31,7 +31,7 @@ def test_raise_for_empty_sequence(self) -> None: def test_raise_for_non_2d_array(self) -> None: # Fails if one of the arrays is not 2D - with pytest.raises(ValueError, match=r"too many values to unpack \(expected 2\)"): + with pytest.raises(ValueError, match=r"too many values to unpack \(expected 2(, got 3)?\)"): get_xy_extrema( densities=[ # valid 2D trace From dde86bbd9745c4dc38a1b917dada72d753d90c30 Mon Sep 17 00:00:00 2001 From: Tomas Pereira de Vasconcelos Date: Fri, 26 Dec 2025 22:28:25 +0800 Subject: [PATCH 4/4] Update ValueErrors in Python 3.14 Signed-off-by: Tomas Pereira de Vasconcelos --- tests/unit/color/test_utils.py | 4 ++-- tests/unit/test_utils.py | 3 ++- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/tests/unit/color/test_utils.py b/tests/unit/color/test_utils.py index 2bce06d2..0494808c 100644 --- a/tests/unit/color/test_utils.py +++ b/tests/unit/color/test_utils.py @@ -56,13 +56,13 @@ def test_to_rgb(color: Color, expected: str) -> None: "hex or rgb color, got 'not-a-color' instead", ), # invalid hex - ("#1234567890", ValueError, "too many values to unpack (expected 3)"), + ("#1234567890", ValueError, "too many values to unpack (expected 3"), ("#ABCDEFGHIJ", ValueError, "invalid literal for int() with base 16"), # invalid rgb ("rgb(0,0,999)", PlotlyError, "rgb colors tuples cannot exceed 255"), # invalid tuple ((1, 2), ValueError, "not enough values to unpack (expected 3, got 2)"), - ((1, 2, 3, 4), ValueError, "too many values to unpack (expected 3)"), + ((1, 2, 3, 4), ValueError, "too many values to unpack (expected 3"), ], ) def test_to_rgb_fails_for_invalid_color( diff --git a/tests/unit/test_utils.py b/tests/unit/test_utils.py index cd070dca..cf35a97e 100644 --- a/tests/unit/test_utils.py +++ b/tests/unit/test_utils.py @@ -1,5 +1,6 @@ from __future__ import annotations +import re from itertools import product from typing import TYPE_CHECKING, TypeVar @@ -31,7 +32,7 @@ def test_raise_for_empty_sequence(self) -> None: def test_raise_for_non_2d_array(self) -> None: # Fails if one of the arrays is not 2D - with pytest.raises(ValueError, match=r"too many values to unpack \(expected 2(, got 3)?\)"): + with pytest.raises(ValueError, match=re.escape(r"too many values to unpack (expected 2")): get_xy_extrema( densities=[ # valid 2D trace