Skip to content

gergosimonyi/celery-empty-group-bug-demo

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

To run this

docker run -d -p 6379:6379 redis
uv sync --frozen
uv run manage.py shell

Then, in the shell

from root.empty_group_bug import run_all_tasks
run_all_tasks()

This will result in

Traceback (most recent call last):
  File "<console>", line 1, in <module>
  File "/.../celery-empty-group-bug-demo/root/empty_group_bug.py", line 37, in run_all_tasks
    all_tasks()
    ~~~~~~~~~^^
  File "/.../celery-empty-group-bug-demo/.venv/lib/python3.13/site-packages/celery/canvas.py", line 955, in __call__
    return self.apply_async(args, kwargs)
           ~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^
  File "/.../celery-empty-group-bug-demo/.venv/lib/python3.13/site-packages/celery/canvas.py", line 1042, in apply_async
    return self.run(args, kwargs, app=app, **(
           ~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^
        dict(self.options, **options) if options else self.options))
        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/.../celery-empty-group-bug-demo/.venv/lib/python3.13/site-packages/celery/canvas.py", line 1067, in run
    tasks, results_from_prepare = self.prepare_steps(
                                  ~~~~~~~~~~~~~~~~~~^
        args, kwargs, self.tasks, root_id, parent_id, link_error, app,
        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
        task_id, group_id, chord, group_index=group_index,
        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    )
    ^
  File "/.../celery-empty-group-bug-demo/.venv/lib/python3.13/site-packages/celery/canvas.py", line 1274, in prepare_steps
    while node.parent:
          ^^^^^^^^^^^
AttributeError: 'NoneType' object has no attribute 'parent'

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages