This allows the more "adventurous" to update their requirements so they
can install the next latest Django version (5.1 and 5.2) even if we
haven't officially supported it. As long as we're on top of Django's
updates, this should be OK for the duration of this Wagtail release's
active support period.
However, do not update the default project template's requirements yet,
since we don't want new projects to be installed with Django versions we
haven't officially supported.
Notably, this changes the behaviour of multi-line HTML tags so that attributes are aligned (https://github.com/rtts/djhtml#new-multi-line-html-elements). The pre-commit hook was already set to use djhtml 3.0.6, which meant that it was making changes that conflicted with the formatting rules enforced by the Makefile and CI.
Relax the upper version bound to <2, because we're unlikely to stay on top of keeping the version listed in testing_extras up to date, and if boto makes breaking changes that violate semver, that's going to affect end-users so we really want to know about it sooner rather than later.
These tests seem to have been written with the intent of testing query construction independently of actually running the queries; to do this, they mock the relevant bits of elasticsearch-py so that no actual server needs to be running. However, this is a bit of a bodge job - it still instantiates the Elasticsearch object when initialising the backend, so *some* version of elasticsearch-py must be installed to run Wagtail's test suite; and furthermore, that installed version must be able to handle EVERY backend's variant of the `Elasticsearch(...)` constructor, regardless of whether it was written for a completely different version.
This breaks down with Elasticsearch 8, which makes backward-incompatible changes to the constructor. Since the CI suite as a whole will test each backend with its corresponding correct version of elasticsearch-py at some point, it's redundant (and a waste of CPU cycles) to repeat those tests in environments with a different ES version (or none at all).
* Fix test migrations for django-taggit 3.0.0 (forthcoming)
The next release of django-taggit [will change slugs to allow_unicode=True](https://github.com/jazzband/django-taggit/pull/797), which breaks our check for missing migrations.
This change is not released yet, but the fix is needed now so that we can run against django-taggit git master for our tests against Django main. It's also dependent on the version bump happening at the django-taggit end: https://github.com/jazzband/django-taggit/pull/800
* Allow django-taggit 3.x as a dependency and drop special case when testing against Django main