Skip to content

fix(deps): update Celery to 5.6.0+ to fix task_id None error#3571

Closed
ANJAN672 wants to merge 4 commits into
augurlabs:mainfrom
ANJAN672:fix/update-celery-to-5.6.0
Closed

fix(deps): update Celery to 5.6.0+ to fix task_id None error#3571
ANJAN672 wants to merge 4 commits into
augurlabs:mainfrom
ANJAN672:fix/update-celery-to-5.6.0

Conversation

@ANJAN672

Copy link
Copy Markdown
Contributor

Updates Celery from ~=5.5 to >=5.6.0 to fix a bug where task_id becomes None during exception handling while executing a task chain within a chord.

This was reported in celery/celery#9774 and fixed in Celery 5.6.0.

Description

  • Updated celery~=5.5celery>=5.6.0 in pyproject.toml
  • Regenerated uv.lock (Celery 5.5.3 → 5.6.2)
  • All unit tests pass ✅

This PR fixes #3458

Notes for Reviewers

  • This is a dependency version bump to pull in an upstream bug fix
  • No code changes required, only pyproject.toml and uv.lock updated
  • Tested locally: Celery imports correctly and all tests pass

Signed commits

  • Yes, I signed my commits.

@MoralCode MoralCode added the waiting This change is waiting for some other changes to land first label Feb 4, 2026
@MoralCode

Copy link
Copy Markdown
Contributor

marking as waiting behind #3336

@MoralCode MoralCode added this to the v0.93.0 milestone Feb 4, 2026
@MoralCode MoralCode removed the waiting This change is waiting for some other changes to land first label Feb 4, 2026
@MoralCode

Copy link
Copy Markdown
Contributor

#3336 has merged. This now requires a rebase but should be good to go as soon as that happens

@MoralCode

Copy link
Copy Markdown
Contributor

taking this over

@MoralCode
MoralCode force-pushed the fix/update-celery-to-5.6.0 branch from 5d3fd4d to 5d54ce7 Compare February 9, 2026 19:31
@MoralCode MoralCode added ready Items tested and seeking additional approvals or a merge. Usually for items under active development dependencies Pull requests that update a dependency file labels Feb 12, 2026
@MoralCode MoralCode moved this to Dev Testing in Augur TSC Feb 15, 2026
sgoggins
sgoggins previously approved these changes Feb 19, 2026
@sgoggins

Copy link
Copy Markdown
Collaborator

This docker build failure message is possibly not related to this PR. It suggests something is off. I do not think celery is the default queue name.

rror: q-1      | 2026-02-19 03:21:21.918387+00:00 [error] <0.749.0> Channel error on connection <0.741.0> (10.89.0.2:55950 -> 10.89.0.5:5672, vhost: 'augur_vhost', user: 'augur'), channel 1:
Error: q-1      | 2026-02-19 03:21:21.918387+00:00 [error] <0.749.0> operation queue.purge caused a channel exception not_found: no queue 'celery' in vhost 'augur_vhost'

@MoralCode

Copy link
Copy Markdown
Contributor

@sgoggins that error is benign. i saw it when messing with the rabbit version and documented it as known benign on the wiki https://github.com/chaoss/augur/wiki

@MoralCode

Copy link
Copy Markdown
Contributor

This does have a more serious error though in the docker build

Stack Trace
augur-1         | [2026-02-19 03:24:59,967: CRITICAL/MainProcess] Unrecoverable error: ImportError("cannot import name 'CredentialProvider' from 'redis' (/augur/.venv/lib/python3.11/site-packages/redis/__init__.py)")
augur-1         | Traceback (most recent call last):
augur-1         |   File "/augur/.venv/lib/python3.11/site-packages/celery/worker/worker.py", line 203, in start
augur-1         |     self.blueprint.start(self)
augur-1         |   File "/augur/.venv/lib/python3.11/site-packages/celery/bootsteps.py", line 112, in start
augur-1         |     self.on_start()
augur-1         |   File "/augur/.venv/lib/python3.11/site-packages/celery/apps/worker.py", line 136, in on_start
augur-1         |     self.emit_banner()
augur-1         |   File "/augur/.venv/lib/python3.11/site-packages/celery/apps/worker.py", line 170, in emit_banner
augur-1         |     ' \n', self.startup_info(artlines=not use_image))),
augur-1         |            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
augur-1         |   File "/augur/.venv/lib/python3.11/site-packages/celery/apps/worker.py", line 232, in startup_info
augur-1         |     results=self.app.backend.as_uri(),
augur-1         |             ^^^^^^^^^^^^^^^^
augur-1         |   File "/augur/.venv/lib/python3.11/site-packages/celery/app/base.py", line 1452, in backend
augur-1         |     self._backend = self._get_backend()
augur-1         |                     ^^^^^^^^^^^^^^^^^^^
augur-1         |   File "/augur/.venv/lib/python3.11/site-packages/celery/app/base.py", line 1117, in _get_backend
augur-1         |     backend, url = backends.by_url(
augur-1         |                    ^^^^^^^^^^^^^^^^
augur-1         |   File "/augur/.venv/lib/python3.11/site-packages/celery/app/backends.py", line 69, in by_url
augur-1         |     return by_name(backend, loader), url
augur-1         |            ^^^^^^^^^^^^^^^^^^^^^^^^
augur-1         |   File "/augur/.venv/lib/python3.11/site-packages/celery/app/backends.py", line 49, in by_name
augur-1         |     cls = symbol_by_name(backend, aliases)
augur-1         |           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
augur-1         |   File "/augur/.venv/lib/python3.11/site-packages/kombu/utils/imports.py", line 59, in symbol_by_name
augur-1         |     module = imp(module_name, package=package, **kwargs)
augur-1         |              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
augur-1         |   File "/usr/local/lib/python3.11/importlib/__init__.py", line 126, in import_module
augur-1         |     return _bootstrap._gcd_import(name[level:], package, level)
augur-1         |            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
augur-1         |   File "<frozen importlib._bootstrap>", line 1204, in _gcd_import
augur-1         |   File "<frozen importlib._bootstrap>", line 1176, in _find_and_load
augur-1         |   File "<frozen importlib._bootstrap>", line 1147, in _find_and_load_unlocked
augur-1         |   File "<frozen importlib._bootstrap>", line 690, in _load_unlocked
augur-1         |   File "<frozen importlib._bootstrap_external>", line 940, in exec_module
augur-1         |   File "<frozen importlib._bootstrap>", line 241, in _call_with_frames_removed
augur-1         |   File "/augur/.venv/lib/python3.11/site-packages/celery/backends/redis.py", line 12, in <module>
augur-1         |     from redis import CredentialProvider
augur-1         | ImportError: cannot import name 'CredentialProvider' from 'redis' (/augur/.venv/lib/python3.11/site-packages/redis/__init__.py)
augur-1         | Creating task logs

@MoralCode

Copy link
Copy Markdown
Contributor

@ANJAN672 are you still interested in helping the maintainers merge this PR? I dont think it can move forward in its current state given the failing CI checks

@MoralCode
MoralCode marked this pull request as draft February 19, 2026 16:07
@MoralCode MoralCode added pending changes PRs that have review comments that have been added but havent been addressed in a while and removed ready Items tested and seeking additional approvals or a merge. Usually for items under active development labels Feb 19, 2026
@ANJAN672

Copy link
Copy Markdown
Contributor Author

@ANJAN672 are you still interested in helping the maintainers merge this PR? I dont think it can move forward in its current state given the failing CI checks

Working on it now !!

Fixes augurlabs#3458

Updates Celery from ~=5.5 to >=5.6.0 to fix a bug where task_id becomes
None during exception handling while executing a task chain within a
chord.

This was reported in celery/celery#9774 and fixed in Celery 5.6.0.

Signed-off-by: ANJAN672 <rockyanjan672@gmail.com>
…in docker

Signed-off-by: ANJAN672 <rockyanjan672@gmail.com>
Signed-off-by: ANJAN672 <rockyanjan672@gmail.com>
@ANJAN672
ANJAN672 force-pushed the fix/update-celery-to-5.6.0 branch from b73af06 to 124c7db Compare February 19, 2026 18:47
@ANJAN672
ANJAN672 marked this pull request as ready for review February 19, 2026 18:48
Signed-off-by: ANJAN672 <rockyanjan672@gmail.com>
@ANJAN672
ANJAN672 force-pushed the fix/update-celery-to-5.6.0 branch from f4cf793 to 314ac2f Compare February 21, 2026 06:28
@ANJAN672

Copy link
Copy Markdown
Contributor Author

@MoralCode and @sgoggins , can u please review this!

@MoralCode MoralCode removed this from the v0.93.0 milestone Mar 6, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

dependencies Pull requests that update a dependency file pending changes PRs that have review comments that have been added but havent been addressed in a while

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Update celery to 5.6.0 to avoid task id none error during exception handling while executing a task chain within a chord

3 participants