celery-types
celery-types copied to clipboard
:seedling: Type stubs for Celery and its related packages
When importing stuff from `celery.contrib` (e.g. `abortable.AbortableTask`) pyright tells me it could not be resolved. It seems to be missing in the stubs.
Hello! I have a problem with the new Task annotations. I installed version 0.13.0 and started receiving typing errors on Task annotations (from https://github.com/sbdchd/celery-types/pull/75) ``` Missing type parameters for generic...
👋 Hello, I am interested in the `kombu` stubs and nothing else. From what I saw, there is no way to simply use the `kombu` typings, I need to download...
Missing `is_eager`, `called_directly`, and `timelimit` among other things. https://docs.celeryq.dev/en/stable/userguide/tasks.html#task-request
The [typeshed repository](https://github.com/python/typeshed) is certainly *the* right place where to put those types. Why not submitting the project to them?
Should this project be renamed given the Modular Typeshed paradigm? http://mypy-lang.blogspot.com/2021/05/the-upcoming-switch-to-modular-typeshed.html
I believe most of the args in `task()` should be optional, eg. all the retry params, and `acks_late`, among others? https://github.com/sbdchd/celery-types/blob/71654791ce05f5a9ccc86e75b59c1579c59beeaa/celery-stubs/app/base.pyi#L110
https://github.com/sbdchd/celery-types/blob/e1750be8b706ff2bc3f7471d0ed0e5f53272af7d/typings/celery/app/__init__.pyi#L13 The args in this function declaration helped me catch an issue. I was using: ```python @celery.shared_task( exponential_backoff = 5 ) def some_func(...): ``` I thought `exponential_backoff` was a celery...
Using Celery 5.2.7 but celery-types version 0.14.0 Maybe it's just not there yet....
Please, consider marking these stubs as `partial` per [PEP-561](https://peps.python.org/pep-0561/#partial-stub-packages). Otherwise, Pylance, for example, reports all untyped imports as missing (try `from celery.backends.database.models import TaskExtended`).