[BUG] Celery Background Callback Manager fails with Non-Key/Value-Backends
@datenzauberai ci sta già lavorando.
Dal 8/4/2026.
Valutazione
Questa issue non è ancora stata valutata.
Descrizione
Describe your context
This applies to background callbacks using the Celery Background Callback Manager. This should be reproducible using the latest version of dash as well.
dash 3.3.0
dash-ag-grid 33.3.3
dash-iconify 0.1.2
dash-mantine-components 2.5.1
dash-testing-stub 0.0.2
Describe the bug
Celery supports multiple backends that are not a BaseKeyValueStoreBackend:
CassandraBackendDatabaseBackendMongoBackendRPCBackend
However, Dash's CeleryManager assumes the backend to be a BaseKeyValueStoreBackend having the methods set and get.
Configuring any of the backends above will result in an error similar to AttributeError: 'DatabaseBackend' object has no attribute 'get' when triggering a background callback.
Backends that that implement BaseKeyValueStoreBackend might also fail, when the parameters passed to set and get do not comply with the backend's requirements (e.g. the FilesystemBackend expects a byte-like object for the key resulting in an error similar to TypeError: sequence item 1: expected a bytes-like object, str found, also see https://github.com/plotly/dash/issues/3116).
Expected behavior
The CeleryManager should either
- support all Celery backends by using
get_resultandstore_resultfromBaseBackendinstead ofgetandsetand using byte-like objects for keys or - make the restriction more explicit by additional documentation and erroring early on when the configured backend does not implement
BaseKeyValueStoreBackendor is otherwise not supported.
Especially the DatabaseBackend and FilesystemBackend would be accessible options without the need for additional infrastructure to execute background callbacks.
- Lingua principale
- Python
- Stelle
- 24.4k
- Fork
- 2.3k
- Merge medio
- 1g 21h
- PR unite (30g)
- 19
Guida per i contributori
Apri la guida per i contributori
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Altre issue di plotly/dash
-
good first issue P3 size: 1 task
Difficoltà 2/5 1-3 ore Idoneità per principianti 68/100
-
enhancement P2 size: 5
Difficoltà 5/5 Più di una settimana Idoneità per principianti 45/100
-
enhancement P3 size: 10+
-
P2 size: 1 task
-
enhancement P3 size: 1
Difficoltà 3/5 1-2 giorni Idoneità per principianti 72/100
Issue simili
-
enhancement
Difficoltà 2/5 1-3 ore Idoneità per principianti 70/100
canonical/paas-charm#368 · 1 commento ·
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 75/100
-
tech debt
Difficoltà 2/5 1-3 ore Idoneità per principianti 75/100
-
addition to tracking list Aperta
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 90/100
StevenBlack/hosts#3256 ·
-
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 90/100
qualcomm/qai-appbuilder#275 ·