Skip to content

Upgrade Django to 6.0.5 and add django-tasks configuration#4633

Open
marcoacierno wants to merge 4 commits intomainfrom
claude/fix-ci-failures-BOXmo
Open

Upgrade Django to 6.0.5 and add django-tasks configuration#4633
marcoacierno wants to merge 4 commits intomainfrom
claude/fix-ci-failures-BOXmo

Conversation

@marcoacierno
Copy link
Copy Markdown
Member

What

  • Upgraded Django from 5.2.8 to 6.0.5
  • Updated django-timezone-field to >=7.1 (was pinned to 7.0)
  • Updated django-autocomplete-light to 4.0.0 (was 3.9.4)
  • Added django-tasks configuration with immediate backend for task execution

The django-tasks configuration uses the ImmediateBackend which executes tasks synchronously, suitable for development and testing environments.

ToDo

  • Verify Django 6.0.5 compatibility with existing codebase
  • Test task execution with the immediate backend
  • Update documentation if needed for new dependencies

https://claude.ai/code/session_012iLUaDFSVctE7tbLx6RTyF

dependabot Bot and others added 4 commits May 5, 2026 22:22
Bumps [django](https://github.com/django/django) from 5.2.8 to 6.0.5.
- [Commits](django/django@5.2.8...6.0.5)

---
updated-dependencies:
- dependency-name: django
  dependency-version: 6.0.4
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
django-timezone-field 7.0 requires django>=3.2,<6.0, which conflicts
with the Django 6.0.5 upgrade. Updating to >=7.1 for Django 6.0 support.

Co-authored-by: Marco Acierno <marcoacierno@users.noreply.github.com>
- Set TASKS to django_tasks ImmediateBackend so modelsearch keeps working
  (Django 6.0 ships its own django.tasks.* with a different Task signature
  that lacks `enqueue_on_commit`, which broke the modelsearch @task decorator).
- Bump django-autocomplete-light from 3.9.4 to 4.0.0 (3.9.4 imports the
  removed `django.utils.itercompat` module).
@vercel
Copy link
Copy Markdown

vercel Bot commented May 6, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
pycon Error Error May 6, 2026 2:24am

@codecov
Copy link
Copy Markdown

codecov Bot commented May 6, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 92.52%. Comparing base (edac1af) to head (8da2aee).

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #4633   +/-   ##
=======================================
  Coverage   92.52%   92.52%           
=======================================
  Files         359      359           
  Lines       10791    10792    +1     
  Branches      821      821           
=======================================
+ Hits         9984     9985    +1     
  Misses        696      696           
  Partials      111      111           
🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@claude
Copy link
Copy Markdown
Contributor

claude Bot commented May 6, 2026

This PR upgrades Django 5.2.8 → 6.0.5, django-autocomplete-light 3.9.4 → 4.0.0, and adds a `TASKS` configuration block using `ImmediateBackend` from django-tasks.

Critical: `ImmediateBackend` in `base.py` affects production

`backend/pycon/settings/base.py:382-386`

The `TASKS` block is set in `base.py` with `ImmediateBackend`, which executes tasks synchronously in the request thread. Since `prod.py` inherits from `base.py` and has no `TASKS` override, production will also run tasks synchronously, blocking HTTP threads. The PR description itself notes this backend is "suitable for development and testing environments." Move this setting to `dev.py` and `test.py` only, or add a proper async backend override in `prod.py`.

`django-tasks` missing as a direct dependency

`backend/pyproject.toml`

`django_tasks.backends.immediate.ImmediateBackend` is referenced in settings, but `django-tasks` is only a transitive dependency (via wagtail). If wagtail ever drops it, the settings will break at runtime with no resolution error. Add it as a direct dependency.

`django_tasks` not in `INSTALLED_APPS`

`backend/pycon/settings/base.py`

Not required for `ImmediateBackend`, but `DatabaseBackend` (the natural production choice) does require it in `INSTALLED_APPS` for migrations. Worth adding now to avoid a future surprise.

Unconfirmed compatibility

The PR description lists open TODO items — verifying Django 6.0.5 compatibility, testing task execution, and updating docs — none of which are confirmed complete. Given this is a major version jump, merging with unverified compatibility is risky.

`django-timezone-field` missing upper bound

Changed from `==7.0` to `>=7.1` with no upper bound. Future `uv lock` runs could pull in breaking major versions. Use `>=7.1,<8.0` to be consistent with other packages in the file (e.g., `countries<1.0.0,>=0.2.0`).

@marcoacierno marcoacierno deployed to pastaporto May 6, 2026 02:38 — with GitHub Actions Active
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants