Skip to content

Set up celery#459

Merged
paulapreuss merged 15 commits intomainfrom
feature/celery-beat
Apr 29, 2026
Merged

Set up celery#459
paulapreuss merged 15 commits intomainfrom
feature/celery-beat

Conversation

@paulapreuss
Copy link
Copy Markdown

@paulapreuss paulapreuss commented Apr 16, 2026

To allow to run scheduled jobs again and fix #381. Used to be handled with Django-Q but being updated due to Django Q being outdated and to share a similar setup with other repositories for easier maintenance. The configuration is mostly identical to what is used on the offgridplanner. I also fixed some errors on the dependabot config in this PR, but it is unrelated to the celery function.

@Bachibouzouk there is already an instance of beat/celery worker running on the server watching the sandbox server, all seems to be working. Simulations can be started, return to the projects page and the simulation status will be updated automatically on refresh when it changes.

Once we merge these changes into main, what should need to be done on the server is:

  • change the branches from which to deploy the celery instances on the server (from feature/celery-beat to main)
  • point to the production database instead of the sandbox one

@paulapreuss paulapreuss changed the title Set up celery for repository Set up celery Apr 16, 2026
@paulapreuss paulapreuss force-pushed the feature/celery-beat branch 3 times, most recently from e5369c5 to d944b88 Compare April 16, 2026 17:53
@paulapreuss paulapreuss marked this pull request as ready for review April 20, 2026 07:57
Copy link
Copy Markdown

@Bachibouzouk Bachibouzouk left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for tackling this! I tested it with a very fast simulation and it did not update the status on the project page (I left it open but did not refresh it to see if the status would update automatically). The comment I made are more like open questions and no blocker to merge :)

Comment thread app/compose/production/app_postgres/celery/flower/start
Comment thread app/compose/production/app_postgres/Dockerfile
Comment thread app/projects/tasks.py
Comment thread app/requirements/base.txt Outdated
@paulapreuss paulapreuss force-pushed the feature/celery-beat branch from a0bcae0 to d151ade Compare April 29, 2026 08:50
@paulapreuss paulapreuss merged commit 966c975 into main Apr 29, 2026
2 checks passed
@paulapreuss paulapreuss deleted the feature/celery-beat branch April 29, 2026 09:03
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.

The notice about the simulation status is not updating under my projects

2 participants