Skip to content

Commit

Permalink
🌈 rename context key
Browse files Browse the repository at this point in the history
WARNING devel odoo.addons.queue_job.utils: `test_queue_job_no_delay` ctx key
found. NO JOB scheduled. Note that this key is deprecated: please use
`queue_job__no_delay`
  • Loading branch information
yelizariev committed May 11, 2024
1 parent cb26050 commit 067207f
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion sync/models/sync_task.py
Original file line number Diff line number Diff line change
Expand Up @@ -125,7 +125,7 @@ def start(
queue_job_or_result = run(
job, trigger._sync_handler, args, raise_on_error=raise_on_error
)
if with_delay and not self.env.context.get("test_queue_job_no_delay"):
if with_delay and not self.env.context.get("queue_job__no_delay"):
job.queue_job_id = queue_job_or_result.db_record()
return job
else:
Expand Down
2 changes: 1 addition & 1 deletion sync/tests/test_trigger_db.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ def setUp(self):
self.env = self.env(
context=dict(
self.env.context,
test_queue_job_no_delay=True, # no jobs thanks
queue_job__no_delay=True, # no jobs thanks
)
)
funcs = self.env["sync.link"]._get_eval_context()
Expand Down

0 comments on commit 067207f

Please sign in to comment.