Skip to content

Commit 4c109d0

Browse files
ulgensddabble
andauthored
Drop support for Python 3.9 (EOL) (#1560)
* Drop support for Python 3.9 (EOL) > As of 2025-10-31, 3.9 has reached the end-of-life phase of its release cycle. https://peps.python.org/pep-0596/ * Removed some missing Python 3.9 references Also removed an unused import, and added GitHub references to the most recent changelog entries. --------- Co-authored-by: Anders <6058745+ddabble@users.noreply.github.com>
1 parent 7749e3b commit 4c109d0

File tree

8 files changed

+14
-26
lines changed

8 files changed

+14
-26
lines changed

.github/workflows/test.yml

Lines changed: 2 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -11,23 +11,12 @@ jobs:
1111
strategy:
1212
fail-fast: false
1313
matrix:
14-
python-version: ['3.9', '3.10', '3.11', '3.12', '3.13', '3.14']
14+
python-version: ['3.10', '3.11', '3.12', '3.13', '3.14']
1515
django-version: ['4.2', '5.0', '5.1', '5.2', '6.0', 'main']
1616

1717
exclude:
18-
# Exclude py3.9 for Django >= 5.0,
19-
# and py3.10 and py3.11 for Django > 5.2
18+
# Exclude py3.10 and py3.11 for Django > 5.2
2019
# and py3.14 for Django < 5.2
21-
- python-version: '3.9'
22-
django-version: '5.0'
23-
- python-version: '3.9'
24-
django-version: '5.1'
25-
- python-version: '3.9'
26-
django-version: '5.2'
27-
- python-version: '3.9'
28-
django-version: '6.0'
29-
- python-version: '3.9'
30-
django-version: 'main'
3120
- python-version: '3.10'
3221
django-version: '6.0'
3322
- python-version: '3.10'

.pre-commit-config.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ repos:
1010
rev: 25.1.0
1111
hooks:
1212
- id: black
13-
language_version: python3.9
13+
language_version: python3.10
1414

1515
- repo: https://github.com/codespell-project/codespell
1616
rev: v2.4.1
@@ -66,4 +66,4 @@ repos:
6666
rev: v3.20.0
6767
hooks:
6868
- id: pyupgrade
69-
args: [--py39-plus]
69+
args: [--py310-plus]

CHANGES.rst

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,9 @@ Changes
44
Unreleased
55
----------
66

7-
- Added support for Python 3.14
8-
- Added support for Django 6.0
7+
- Added support for Python 3.14 (gh-1529)
8+
- Added support for Django 6.0 (gh-1529)
9+
- Dropped support for Python 3.9 (gh-1560)
910

1011
3.10.1 (2025-06-20)
1112
-------------------

README.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ This app supports the following combinations of Django and Python:
4141
========== ========================
4242
Django Python
4343
========== ========================
44-
4.2 3.9, 3.10, 3.11, 3.12, 3.13
44+
4.2 3.10, 3.11, 3.12, 3.13
4545
5.0 3.10, 3.11, 3.12, 3.13
4646
5.1 3.10, 3.11, 3.12, 3.13
4747
5.2 3.10, 3.11, 3.12, 3.13, 3.14

docs/index.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ This app supports the following combinations of Django and Python:
3737
========== =======================
3838
Django Python
3939
========== =======================
40-
4.2 3.9, 3.10, 3.11, 3.12, 3.13
40+
4.2 3.10, 3.11, 3.12, 3.13
4141
5.0 3.10, 3.11, 3.12, 3.13
4242
5.1 3.10, 3.11, 3.12, 3.13
4343
5.2 3.10, 3.11, 3.12, 3.13, 3.14

pyproject.toml

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ maintainers = [
1515
authors = [
1616
{ name = "Corey Bertram", email = "corey@qr7.com" },
1717
]
18-
requires-python = ">=3.9"
18+
requires-python = ">=3.10"
1919
classifiers = [
2020
"Development Status :: 5 - Production/Stable",
2121
"Environment :: Web Environment",
@@ -28,7 +28,6 @@ classifiers = [
2828
"License :: OSI Approved :: BSD License",
2929
"Programming Language :: Python",
3030
"Programming Language :: Python :: 3 :: Only",
31-
"Programming Language :: Python :: 3.9",
3231
"Programming Language :: Python :: 3.10",
3332
"Programming Language :: Python :: 3.11",
3433
"Programming Language :: Python :: 3.12",
@@ -80,12 +79,12 @@ fragments = [
8079
[tool.black]
8180
line-length = 88
8281
target-version = [
83-
"py39",
82+
"py310",
8483
]
8584

8685
[tool.isort]
8786
profile = "black"
88-
py_version = "39"
87+
py_version = "310"
8988

9089
[tool.codespell]
9190
skip = "AUTHORS.rst,*.po"

simple_history/template_utils.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import dataclasses
22
from os.path import commonprefix
3-
from typing import Any, Final, Union
3+
from typing import Any, Final
44

55
from django.db.models import ManyToManyField, Model
66
from django.utils.html import conditional_escape
@@ -134,7 +134,7 @@ def stringify_delta_change_values(
134134
if all the passed elements are safe strings.
135135
"""
136136

137-
def stringify_value(value: Any) -> Union[str, SafeString]:
137+
def stringify_value(value: Any) -> str | SafeString:
138138
# If `value` is a list, stringify each element using `str()` instead of
139139
# `repr()` (the latter is the default when calling `list.__str__()`)
140140
if isinstance(value, list):

tox.ini

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,6 @@ envlist =
99

1010
[gh-actions]
1111
python =
12-
3.9: py39
1312
3.10: py310
1413
3.11: py311, docs, lint
1514
3.12: py312

0 commit comments

Comments
 (0)