1
0
mirror of https://github.com/django/django.git synced 2025-10-25 14:46:09 +00:00

[5.2.x] Refs #35844 -- Doc'd Python 3.14 compatibility.

Backport of 56977b466c from main.
This commit is contained in:
Mariusz Felisiak
2025-10-13 16:34:26 +02:00
parent 83f6fe810d
commit a8c9b5b263
14 changed files with 26 additions and 22 deletions

View File

@@ -29,7 +29,7 @@ jobs:
- name: Set up Python - name: Set up Python
uses: actions/setup-python@v5 uses: actions/setup-python@v5
with: with:
python-version: '3.13' python-version: '3.14'
cache: 'pip' cache: 'pip'
cache-dependency-path: 'docs/requirements.txt' cache-dependency-path: 'docs/requirements.txt'
- run: python -m pip install -r docs/requirements.txt - run: python -m pip install -r docs/requirements.txt
@@ -47,7 +47,7 @@ jobs:
- name: Set up Python - name: Set up Python
uses: actions/setup-python@v5 uses: actions/setup-python@v5
with: with:
python-version: '3.13' python-version: '3.14'
- run: python -m pip install blacken-docs - run: python -m pip install blacken-docs
- name: Build docs - name: Build docs
run: | run: |

View File

@@ -27,7 +27,7 @@ jobs:
- name: Set up Python - name: Set up Python
uses: actions/setup-python@v5 uses: actions/setup-python@v5
with: with:
python-version: '3.13' python-version: '3.14'
- run: python -m pip install flake8 - run: python -m pip install flake8
- name: flake8 - name: flake8
# Pinned to v3.0.0. # Pinned to v3.0.0.
@@ -44,7 +44,7 @@ jobs:
- name: Set up Python - name: Set up Python
uses: actions/setup-python@v5 uses: actions/setup-python@v5
with: with:
python-version: '3.13' python-version: '3.14'
- run: python -m pip install "isort<6" - run: python -m pip install "isort<6"
- name: isort - name: isort
# Pinned to v3.0.0. # Pinned to v3.0.0.

View File

@@ -20,7 +20,7 @@ jobs:
- '3.11' - '3.11'
- '3.12' - '3.12'
- '3.13' - '3.13'
- '3.14-dev' - '3.14'
name: Windows, SQLite, Python ${{ matrix.python-version }} name: Windows, SQLite, Python ${{ matrix.python-version }}
continue-on-error: true continue-on-error: true
steps: steps:
@@ -47,7 +47,7 @@ jobs:
- name: Set up Python - name: Set up Python
uses: actions/setup-python@v5 uses: actions/setup-python@v5
with: with:
python-version: '3.13' python-version: '3.14'
cache: 'pip' cache: 'pip'
- name: Install libmemcached-dev for pylibmc - name: Install libmemcached-dev for pylibmc
run: sudo apt-get install libmemcached-dev run: sudo apt-get install libmemcached-dev
@@ -146,7 +146,7 @@ jobs:
- name: Set up Python - name: Set up Python
uses: actions/setup-python@v5 uses: actions/setup-python@v5
with: with:
python-version: '3.13' python-version: '3.14'
cache: 'pip' cache: 'pip'
cache-dependency-path: 'tests/requirements/py3.txt' cache-dependency-path: 'tests/requirements/py3.txt'
- name: Install libmemcached-dev for pylibmc - name: Install libmemcached-dev for pylibmc
@@ -182,7 +182,7 @@ jobs:
- name: Set up Python - name: Set up Python
uses: actions/setup-python@v5 uses: actions/setup-python@v5
with: with:
python-version: '3.13' python-version: '3.14'
cache: 'pip' cache: 'pip'
cache-dependency-path: 'tests/requirements/py3.txt' cache-dependency-path: 'tests/requirements/py3.txt'
- name: Install libmemcached-dev for pylibmc - name: Install libmemcached-dev for pylibmc
@@ -227,7 +227,7 @@ jobs:
- name: Set up Python - name: Set up Python
uses: actions/setup-python@v5 uses: actions/setup-python@v5
with: with:
python-version: '3.13' python-version: '3.14'
cache: 'pip' cache: 'pip'
cache-dependency-path: 'tests/requirements/py3.txt' cache-dependency-path: 'tests/requirements/py3.txt'
- name: Install libmemcached-dev for pylibmc - name: Install libmemcached-dev for pylibmc

View File

@@ -24,7 +24,7 @@ jobs:
- name: Set up Python - name: Set up Python
uses: actions/setup-python@v5 uses: actions/setup-python@v5
with: with:
python-version: '3.13' python-version: '3.14'
cache: 'pip' cache: 'pip'
cache-dependency-path: 'tests/requirements/py3.txt' cache-dependency-path: 'tests/requirements/py3.txt'
- name: Install libmemcached-dev for pylibmc - name: Install libmemcached-dev for pylibmc
@@ -61,7 +61,7 @@ jobs:
- name: Set up Python - name: Set up Python
uses: actions/setup-python@v5 uses: actions/setup-python@v5
with: with:
python-version: '3.13' python-version: '3.14'
cache: 'pip' cache: 'pip'
cache-dependency-path: 'tests/requirements/py3.txt' cache-dependency-path: 'tests/requirements/py3.txt'
- name: Install libmemcached-dev for pylibmc - name: Install libmemcached-dev for pylibmc

View File

@@ -23,7 +23,7 @@ jobs:
strategy: strategy:
matrix: matrix:
python-version: python-version:
- '3.13' - '3.14'
name: Windows, SQLite, Python ${{ matrix.python-version }} name: Windows, SQLite, Python ${{ matrix.python-version }}
steps: steps:
- name: Checkout - name: Checkout

View File

@@ -53,7 +53,7 @@ Django version Python versions
4.2 3.8, 3.9, 3.10, 3.11, 3.12 (added in 4.2.8) 4.2 3.8, 3.9, 3.10, 3.11, 3.12 (added in 4.2.8)
5.0 3.10, 3.11, 3.12 5.0 3.10, 3.11, 3.12
5.1 3.10, 3.11, 3.12, 3.13 (added in 5.1.3) 5.1 3.10, 3.11, 3.12, 3.13 (added in 5.1.3)
5.2 3.10, 3.11, 3.12, 3.13 5.2 3.10, 3.11, 3.12, 3.13, 3.14 (added in 5.2.8)
============== =============== ============== ===============
For each version of Python, only the latest micro release (A.B.C) is officially For each version of Python, only the latest micro release (A.B.C) is officially

View File

@@ -2,7 +2,7 @@
How to install Django on Windows How to install Django on Windows
================================ ================================
This document will guide you through installing Python 3.13 and Django on This document will guide you through installing Python 3.14 and Django on
Windows. It also provides instructions for setting up a virtual environment, Windows. It also provides instructions for setting up a virtual environment,
which makes it easier to work on Python projects. This is meant as a beginner's which makes it easier to work on Python projects. This is meant as a beginner's
guide for users working on Django projects and does not reflect how Django guide for users working on Django projects and does not reflect how Django
@@ -18,7 +18,7 @@ Install Python
============== ==============
Django is a Python web framework, thus requiring Python to be installed on your Django is a Python web framework, thus requiring Python to be installed on your
machine. At the time of writing, Python 3.13 is the latest version. machine. At the time of writing, Python 3.14 is the latest version.
To install Python on your machine go to https://www.python.org/downloads/. The To install Python on your machine go to https://www.python.org/downloads/. The
website should offer you a download button for the latest Python version. website should offer you a download button for the latest Python version.

View File

@@ -238,6 +238,7 @@ this. For a small app like polls, this process isn't too difficult.
"Programming Language :: Python :: 3.11", "Programming Language :: Python :: 3.11",
"Programming Language :: Python :: 3.12", "Programming Language :: Python :: 3.12",
"Programming Language :: Python :: 3.13", "Programming Language :: Python :: 3.13",
"Programming Language :: Python :: 3.14",
"Topic :: Internet :: WWW/HTTP", "Topic :: Internet :: WWW/HTTP",
"Topic :: Internet :: WWW/HTTP :: Dynamic Content", "Topic :: Internet :: WWW/HTTP :: Dynamic Content",
] ]

View File

@@ -4,7 +4,8 @@ Django 5.2.8 release notes
*Expected November 5, 2025* *Expected November 5, 2025*
Django 5.2.8 fixes several bugs in 5.2.7. Django 5.2.8 fixes several bugs in 5.2.7 and adds compatibility with Python
3.14.
Bugfixes Bugfixes
======== ========

View File

@@ -23,8 +23,9 @@ end in April 2026.
Python compatibility Python compatibility
==================== ====================
Django 5.2 supports Python 3.10, 3.11, 3.12, and 3.13. We **highly recommend** Django 5.2 supports Python 3.10, 3.11, 3.12, 3.13, and 3.14 (as of 5.2.8). We
and only officially support the latest release of each series. **highly recommend** and only officially support the latest release of each
series.
.. _whats-new-5.2: .. _whats-new-5.2:

View File

@@ -31,6 +31,7 @@ classifiers = [
"Programming Language :: Python :: 3.11", "Programming Language :: Python :: 3.11",
"Programming Language :: Python :: 3.12", "Programming Language :: Python :: 3.12",
"Programming Language :: Python :: 3.13", "Programming Language :: Python :: 3.13",
"Programming Language :: Python :: 3.14",
"Topic :: Internet :: WWW/HTTP", "Topic :: Internet :: WWW/HTTP",
"Topic :: Internet :: WWW/HTTP :: Dynamic Content", "Topic :: Internet :: WWW/HTTP :: Dynamic Content",
"Topic :: Internet :: WWW/HTTP :: WSGI", "Topic :: Internet :: WWW/HTTP :: WSGI",

View File

@@ -185,7 +185,7 @@ class MailTests(MailTestsMixin, SimpleTestCase):
"""Line length check should encode the payload supporting `surrogateescape`. """Line length check should encode the payload supporting `surrogateescape`.
Following https://github.com/python/cpython/issues/76511, newer Following https://github.com/python/cpython/issues/76511, newer
versions of Python (3.11.9, 3.12.3 and 3.13) ensure that a message's versions of Python (3.11.9, 3.12.3 and 3.13+) ensure that a message's
payload is encoded with the provided charset and `surrogateescape` is payload is encoded with the provided charset and `surrogateescape` is
used as the error handling strategy. used as the error handling strategy.

View File

@@ -6,8 +6,8 @@ black
docutils >= 0.19 docutils >= 0.19
geoip2 geoip2
jinja2 >= 2.11.0 jinja2 >= 2.11.0
numpy; python_version < '3.14' numpy
Pillow >= 6.2.1; sys.platform != 'win32' or python_version < '3.14' Pillow >= 6.2.1
# pylibmc/libmemcached can't be built on Windows. # pylibmc/libmemcached can't be built on Windows.
pylibmc; sys_platform != 'win32' pylibmc; sys_platform != 'win32'
pymemcache >= 3.4.0 pymemcache >= 3.4.0

View File

@@ -26,7 +26,7 @@ setenv =
PYTHONDONTWRITEBYTECODE=1 PYTHONDONTWRITEBYTECODE=1
deps = deps =
-e . -e .
py{3,310,311,312,313,py3}: -rtests/requirements/py3.txt py{3,310,311,312,313,314,py3}: -rtests/requirements/py3.txt
postgres: -rtests/requirements/postgres.txt postgres: -rtests/requirements/postgres.txt
mysql: -rtests/requirements/mysql.txt mysql: -rtests/requirements/mysql.txt
oracle: -rtests/requirements/oracle.txt oracle: -rtests/requirements/oracle.txt