Here is a patch for it, but I'm afraid it then just stumbles on a follow-up error about django:
344s autopkgtest [06:02:28]: test command1: [----------------------- 344s /tmp/autopkgtest.LCD785/build.iLk/src/runtests.py:61: RemovedInDjango50Warning: The extra_tests argument is deprecated. 344s failures = test_runner.run_tests(['bootstrapform'], test_args) 344s Found 1 test(s). 344s Traceback (most recent call last): 344s File "/tmp/autopkgtest.LCD785/build.iLk/src/runtests.py", line 66, in <module> 344s runtests(*sys.argv[1:]) 344s File "/tmp/autopkgtest.LCD785/build.iLk/src/runtests.py", line 61, in runtests 344s failures = test_runner.run_tests(['bootstrapform'], test_args) 344s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 344s File "/usr/lib/python3/dist-packages/django/test/runner.py", line 1060, in run_tests 344s self.run_checks(databases) 344s File "/usr/lib/python3/dist-packages/django/test/runner.py", line 977, in run_checks 344s call_command("check", verbosity=self.verbosity, databases=databases) 344s File "/usr/lib/python3/dist-packages/django/core/management/__init__.py", line 110, in call_command 344s app_name = get_commands()[command_name] 344s ^^^^^^^^^^^^^^ 344s File "/usr/lib/python3/dist-packages/django/core/management/__init__.py", line 76, in get_commands 344s for app_config in reversed(apps.get_app_configs()): 344s ^^^^^^^^^^^^^^^^^^^^^^ 344s File "/usr/lib/python3/dist-packages/django/apps/registry.py", line 147, in get_app_configs 344s self.check_apps_ready() 344s File "/usr/lib/python3/dist-packages/django/apps/registry.py", line 138, in check_apps_ready 344s raise AppRegistryNotReady("Apps aren't loaded yet.") 344s django.core.exceptions.AppRegistryNotReady: Apps aren't loaded yet. Upstream[1] seems quite dead: last commit was 6 years ago. 1. https://github.com/tzangms/django-bootstrap-form
Description: replace distutils' StrictVersion with packaging's Version Python distutils was removed in python 3.12. The recommendation[1] from PEP-0632 is to replace distutils.version with the packaging package. . 1. https://peps.python.org/pep-0632/#migration-advice Author: Andreas Hasenack <andr...@canonical.com> Origin: vendor Bug: TBD Forwarded: TBD Bug-Ubuntu: https://bugs.launchpad.net/ubuntu/+source/python-django-bootstrap-form/+bug/2050093 Forwarded: <URL|no|not-needed, useless if you have a Bug field, optional> Last-Update: 2024-01-22 --- a/bootstrapform/meta.py +++ b/bootstrapform/meta.py @@ -1,5 +1,5 @@ -from distutils.version import StrictVersion +from packaging.version import Version -VERSION = StrictVersion('3.4') +VERSION = Version('3.4') --- a/bootstrapform/tests.py +++ b/bootstrapform/tests.py @@ -1,5 +1,5 @@ import os -from distutils.version import StrictVersion +from packaging.version import Version import django from django.test import TestCase @@ -43,7 +43,7 @@ html = Template("{% load bootstrap %}{{ form|bootstrap }}").render(Context({'form': form})) - if StrictVersion(django.get_version()) >= StrictVersion('4.0'): + if Version(django.get_version()) >= Version('4.0'): fixture = 'basic_dj40.html' else: fixture = 'basic.html' @@ -59,7 +59,7 @@ html = Template("{% load bootstrap %}{{ form|bootstrap_horizontal }}").render(Context({'form': form})) - if StrictVersion(django.get_version()) >= StrictVersion('4.0'): + if Version(django.get_version()) >= Version('4.0'): fixture = 'horizontal_dj40.html' else: fixture = 'horizontal.html'