The Fix
pip install celery==5.1.0b1
Based on closed celery/celery issue #5889 · PR/commit linked
Production note: This usually shows up under retries/timeouts. Treat it as a side-effect risk until you can verify behavior with a canary + real traffic.
@@ -203,6 +203,24 @@ def __ne__(self, other):
+def _evaluate_entry_args(entry_args):
+ if not entry_args:
+ return []
Traceback (most recent call last):
File "/home/ah/virtualenv/lib/python3.5/site-packages/celery/beat.py", line 273, in apply_entry
result = self.apply_async(entry, producer=producer, advance=False)
File "/home/ah/virtualenv/lib/python3.5/site-packages/celery/beat.py", line 401, in apply_async
entry, exc=exc)), sys.exc_info()[2])
File "/home/ah/virtualenv/lib/python3.5/site-packages/vine/five.py", line 194, in reraise
raise value.with_traceback(tb)
File "/home/ah/virtualenv/lib/python3.5/site-packages/celery/beat.py", line 388, in apply_async
entry_kwargs = {k: v() if isinstance(v, BeatLazyFunc) else v for k, v in entry.kwargs.items()}
celery.beat.SchedulingError: Couldn't apply scheduled task sync_products_for_source_40023: 'NoneType' object has no attribute 'items'
Re-run the minimal reproduction on your broken version, then apply the fix and re-run.
Option A — Upgrade to fixed release\npip install celery==5.1.0b1\nWhen NOT to use: Do not apply this fix if the application relies on NoneType kwargs for valid behavior.\n\n
Why This Fix Works in Production
- Trigger: result = self.apply_async(entry, producer=producer, advance=False)
- Mechanism: The error occurs when a NoneType object is passed instead of expected kwargs in the beat scheduler
- Why the fix works: Safeguards against schedule entries without kwargs, addressing the issue where a NoneType object causes an error in the beat scheduler. (first fixed release: 5.1.0b1).
- If left unfixed, the same config can fail only in production (env differences), causing startup failures or partial feature outages.
Why This Breaks in Prod
- Shows up under Python 3.5 in real deployments (not just unit tests).
- The error occurs when a NoneType object is passed instead of expected kwargs in the beat scheduler
- Surfaces as: Traceback (most recent call last):
Proof / Evidence
- GitHub issue: #5889
- Fix PR: https://github.com/celery/celery/pull/6619
- First fixed release: 5.1.0b1
- Reproduced locally: No (not executed)
- Last verified: 2026-02-09
- Confidence: 0.85
- Did this fix it?: Yes (upstream fix exists)
- Own content ratio: 0.40
Discussion
High-signal excerpts from the issue thread (symptoms, repros, edge-cases).
“I confirm the problem. Please, reopen. The fix would be similar to https://github.com/celery/celery/pull/5631.”
“> I confirm the problem. Please, reopen. The fix would be similar to #5631. if you have time please check #6619”
Failure Signature (Search String)
- result = self.apply_async(entry, producer=producer, advance=False)
Error Message
Stack trace
Error Message
-------------
Traceback (most recent call last):
File "/home/ah/virtualenv/lib/python3.5/site-packages/celery/beat.py", line 273, in apply_entry
result = self.apply_async(entry, producer=producer, advance=False)
File "/home/ah/virtualenv/lib/python3.5/site-packages/celery/beat.py", line 401, in apply_async
entry, exc=exc)), sys.exc_info()[2])
File "/home/ah/virtualenv/lib/python3.5/site-packages/vine/five.py", line 194, in reraise
raise value.with_traceback(tb)
File "/home/ah/virtualenv/lib/python3.5/site-packages/celery/beat.py", line 388, in apply_async
entry_kwargs = {k: v() if isinstance(v, BeatLazyFunc) else v for k, v in entry.kwargs.items()}
celery.beat.SchedulingError: Couldn't apply scheduled task sync_products_for_source_40023: 'NoneType' object has no attribute 'items'
Minimal Reproduction
Traceback (most recent call last):
File "/home/ah/virtualenv/lib/python3.5/site-packages/celery/beat.py", line 273, in apply_entry
result = self.apply_async(entry, producer=producer, advance=False)
File "/home/ah/virtualenv/lib/python3.5/site-packages/celery/beat.py", line 401, in apply_async
entry, exc=exc)), sys.exc_info()[2])
File "/home/ah/virtualenv/lib/python3.5/site-packages/vine/five.py", line 194, in reraise
raise value.with_traceback(tb)
File "/home/ah/virtualenv/lib/python3.5/site-packages/celery/beat.py", line 388, in apply_async
entry_kwargs = {k: v() if isinstance(v, BeatLazyFunc) else v for k, v in entry.kwargs.items()}
celery.beat.SchedulingError: Couldn't apply scheduled task sync_products_for_source_40023: 'NoneType' object has no attribute 'items'
Environment
- Python: 3.5
What Broke
The application fails to schedule tasks, leading to missed executions and potential downtime.
Why It Broke
The error occurs when a NoneType object is passed instead of expected kwargs in the beat scheduler
Fix Options (Details)
Option A — Upgrade to fixed release Safe default (recommended)
pip install celery==5.1.0b1
Use when you can deploy the upstream fix. It is usually lower-risk than long-lived workarounds.
Fix reference: https://github.com/celery/celery/pull/6619
First fixed release: 5.1.0b1
Last verified: 2026-02-09. Validate in your environment.
When NOT to Use This Fix
- Do not apply this fix if the application relies on NoneType kwargs for valid behavior.
Verify Fix
Re-run the minimal reproduction on your broken version, then apply the fix and re-run.
Did This Fix Work in Your Case?
Quick signal helps us prioritize which fixes to verify and improve.
Prevention
- Capture the exact failing error string in logs and tests so you can reproduce via a minimal script.
- Pin production dependencies and upgrade only with a reproducible test that hits the failing path.
Version Compatibility Table
| Version | Status |
|---|---|
| 5.1.0b1 | Fixed |
Related Issues
No related fixes found.
Sources
We don’t republish the full GitHub discussion text. Use the links above for context.