Skip to content

Commit 4fa1288

Browse files
authored
Upgrade to Python 3.13 (#315)
Signed-off-by: tdruez <[email protected]>
1 parent 67e56af commit 4fa1288

File tree

34 files changed

+31
-26
lines changed

34 files changed

+31
-26
lines changed

.github/workflows/create-github-release.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,3 +16,4 @@ jobs:
1616
with:
1717
generate_release_notes: true
1818
draft: false
19+
files: dist/*

.github/workflows/run-unit-tests.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ jobs:
3939
- name: Set up Python
4040
uses: actions/setup-python@v5
4141
with:
42-
python-version: "3.12"
42+
python-version: "3.13"
4343

4444
- name: Install python-ldap OS dependencies
4545
run: |

.readthedocs.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ version: 2
88
build:
99
os: ubuntu-22.04
1010
tools:
11-
python: "3.12"
11+
python: "3.13"
1212

1313
# Optionally declare the Python requirements required to build your docs
1414
python:

CHANGELOG.rst

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,10 @@ Release notes
33

44
### Version 5.3.1-dev (unreleased)
55

6+
- Upgrade Python version to 3.13 and Django to 5.2.x
7+
https://github.com/aboutcode-org/dejacode/pull/315
8+
https://github.com/aboutcode-org/dejacode/pull/312
9+
610
- Add new `is_locked` "Locked inventory" field to the ProductStatus model.
711
When a Product is locked through his status, its inventory cannot be modified.
812
https://github.com/aboutcode-org/dejacode/issues/189

Dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
# See https://aboutcode.org for more information about AboutCode FOSS projects.
77
#
88

9-
FROM python:3.12-slim
9+
FROM python:3.13-slim
1010

1111
LABEL org.opencontainers.image.source="https://github.com/aboutcode-org/dejacode"
1212
LABEL org.opencontainers.image.description="DejaCode"

Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
# See https://aboutcode.org for more information about AboutCode FOSS projects.
77
#
88

9-
PYTHON_EXE=python3.12
9+
PYTHON_EXE=python3.13
1010
VENV_LOCATION=.venv
1111
ACTIVATE?=. ${VENV_LOCATION}/bin/activate;
1212
MANAGE=${VENV_LOCATION}/bin/python manage.py

dejacode_toolkit/csaf/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ $ pip install 'datamodel-code-generator[http]'
99
Generate the models
1010
-------------------
1111

12-
$ TARGET_PYTHON_VERSION=3.12
12+
$ TARGET_PYTHON_VERSION=3.13
1313
$ datamodel-codegen \
1414
--input dejacode_toolkit/csaf/schema_v2.0/csaf_json_schema.json \
1515
--output dejacode_toolkit/csaf/ \

dejacode_toolkit/download.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,13 +6,13 @@
66
# See https://aboutcode.org for more information about AboutCode FOSS projects.
77
#
88

9-
import cgi
109
import socket
1110
from pathlib import Path
1211
from urllib.parse import unquote
1312
from urllib.parse import urlparse
1413

1514
from django.template.defaultfilters import filesizeformat
15+
from django.utils.http import parse_header_parameters
1616

1717
import requests
1818

@@ -55,7 +55,7 @@ def collect_package_data(url):
5555
)
5656

5757
content_disposition = response.headers.get("content-disposition", "")
58-
_, params = cgi.parse_header(content_disposition)
58+
_, params = parse_header_parameters(content_disposition)
5959

6060
filename = params.get("filename")
6161
if not filename:

docs/doc_maintenance.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ That will create a /dejacode directory in your working directory.
2828
Now you can install the dependencies in a virtualenv::
2929

3030
cd dejacode
31-
python3.12 -m venv .
31+
python3.13 -m venv .
3232
source bin/activate
3333

3434
Now you can build the HTML documents locally::

docs/installation.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -179,7 +179,7 @@ Pre-installation Checklist
179179

180180
Before you install DejaCode, make sure you have the following prerequisites:
181181

182-
#. **Python: versions 3.12** found at https://www.python.org/downloads/
182+
#. **Python: versions 3.13** found at https://www.python.org/downloads/
183183
#. **Git**: most recent release available at https://git-scm.com/
184184
#. **PostgreSQL**: release 16 or later found at https://www.postgresql.org/ or
185185
https://postgresapp.com/ on macOS

0 commit comments

Comments
 (0)