From a8774abd91108baa70eb936c5ad5a736dd646b5b Mon Sep 17 00:00:00 2001 From: Baptiste Mispelon Date: Sat, 2 Nov 2024 11:43:14 +0100 Subject: [PATCH] Fixed docker image and added comments after review --- .github/workflows/tests.yml | 2 ++ Dockerfile | 2 +- requirements.txt | 4 +++- 3 files changed, 6 insertions(+), 2 deletions(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index b52800e..9ed0b00 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -15,6 +15,8 @@ permissions: env: DJANGO_SETTINGS_MODULE: tracdjangoplugin.settings_tests + # passlib has a conditional import for `crypt` which is going away in python 3.13 + # and therefore throwing warnings PYTHONWARNINGS: > error, default:::passlib.utils, diff --git a/Dockerfile b/Dockerfile index e385073..afdb103 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,5 +1,5 @@ # pull official base image -FROM python:3.12-slim-bookworm +FROM python:3.11-slim-bookworm # set work directory WORKDIR /code diff --git a/requirements.txt b/requirements.txt index 048d462..166a748 100644 --- a/requirements.txt +++ b/requirements.txt @@ -5,7 +5,9 @@ psycopg2==2.9.9 --no-binary=psycopg2 Django==4.2.16 libsass==0.23.0 -# Optional Trac dependencies that make DeprecationWarning go away +# Optional Trac dependencies that make DeprecationWarning go away. +# When upgrading Trac or Python, check if these dependencies are still needed +# by uninstalling them and running the test suite (or CI) with PYTHONWARNINGS=error multipart==1.1.0 passlib==1.7.4