Repository navigation
[REF] queue: sync OCA 18.0 (2026-09-22) - #2
Merged
Merged
Conversation
Adapt to the new multi company system.
Prevent crash when the function is not defined.
Currently translated at 100.0% (13 of 13 strings) Translation: queue-18.0/queue-18.0-queue_job_profiler Translate-URL: https://translation.odoo-community.org/projects/queue-18-0/queue-18-0-queue_job_profiler/it/
Broken by job acquisition refactoring OCA#941
Currently translated at 100.0% (156 of 156 strings) Translation: queue-18.0/queue-18.0-queue_job Translate-URL: https://translation.odoo-community.org/projects/queue-18-0/queue-18-0-queue_job/fr/
Currently translated at 100.0% (156 of 156 strings) Translation: queue-18.0/queue-18.0-queue_job Translate-URL: https://translation.odoo-community.org/projects/queue-18-0/queue-18-0-queue_job/fr/
Currently translated at 100.0% (6 of 6 strings) Translation: queue-18.0/queue-18.0-queue_job_cron Translate-URL: https://translation.odoo-community.org/projects/queue-18-0/queue-18-0-queue_job_cron/fr/
Currently translated at 100.0% (5 of 5 strings) Translation: queue-18.0/queue-18.0-queue_job_subscribe Translate-URL: https://translation.odoo-community.org/projects/queue-18-0/queue-18-0-queue_job_subscribe/sl/
Methods patched with _patch_method leads to a lot of warnings during
tests that look like:
2026-05-22 08:44:57,099 1 INFO testdb odoo.tests.common: /odoo/external-src/queue/queue_job/models/base.py:270:_patch_method setting edi.exchange.record.action_exchange_generate to <function EDIExchangeRecord.action_exchange_generate at 0x7f23b62a0680>
Stack (most recent call last):
File "/usr/local/bin/odoo", line 8, in <module>
odoo.cli.main()
File "/odoo/src/odoo/cli/command.py", line 66, in main
o.run(args)
File "/odoo/src/odoo/cli/server.py", line 182, in run
main(args)
File "/odoo/src/odoo/cli/server.py", line 175, in main
rc = odoo.service.server.start(preload=preload, stop=stop)
File "/odoo/src/odoo/service/server.py", line 1457, in start
rc = server.run(preload, stop)
File "/odoo/src/odoo/service/server.py", line 622, in run
rc = preload_registries(preload)
File "/odoo/src/odoo/service/server.py", line 1388, in preload_registries
result = loader.run_suite(post_install_suite, global_report=registry._assertion_report)
File "/odoo/src/odoo/tests/loader.py", line 118, in run_suite
suite(results)
File "/usr/local/lib/python3.12/unittest/suite.py", line 84, in __call__
return self.run(*args, **kwds)
File "/odoo/src/odoo/tests/suite.py", line 49, in run
self._tearDownPreviousClass(None, result)
File "/odoo/src/odoo/tests/suite.py", line 190, in _tearDownPreviousClass
super()._tearDownPreviousClass(test, result)
File "/odoo/src/odoo/tests/suite.py", line 112, in _tearDownPreviousClass
previousClass.doClassCleanups()
File "/odoo/src/odoo/tests/case.py", line 247, in doClassCleanups
function(*args, **kwargs)
File "/odoo/src/odoo/tests/common.py", line 989, in reset_changes
cls.registry.setup_models(cr)
File "/usr/local/lib/python3.12/site-packages/decorator.py", line 232, in fun
return caller(func, *(extras + args), **kw)
File "/odoo/src/odoo/tools/func.py", line 97, in locked
return func(inst, *args, **kwargs)
File "/odoo/src/odoo/modules/registry.py", line 375, in setup_models
model._register_hook()
File "/odoo/external-src/edi-framework/edi_queue_oca/models/edi_exchange_record.py", line 26, in _register_hook
self._patch_method(function, self._patch_job_auto_delay(function))
File "/odoo/external-src/queue/queue_job/models/base.py", line 270, in _patch_method
setattr(cls, name, wrapped)
File "/odoo/src/odoo/tests/common.py", line 971, in metamodel_setattr
_logger.runbot(
File "/odoo/src/odoo/netsvc.py", line 360, in runbot
self.log(logging.RUNBOT, message, *args, **kws)
Add a new "paused" option on channel configuration. A paused channel is equivalent to a channel with no capacity: it yields no job and also blocks all its subchannels. It still needs a restart of the jobrunner, so it does not allow dynamic pause/resume, but hot reload may be added later in OCA#765. It still is an improvement over setting the capacity at 0, because it keeps the capacity in the configuration (removing the option in the config restores the initial capacity). Also, it does not require changing the channel of a job, which is an issue when resuming paused jobs (they should go back to their former channel to be resumed with their expected properties related to capacity/sequential/throttle).
(cherry picked from commit 47b8c48) [ported to 18.0: isinstance union syntax for ruff UP038]
…n_temporary_env (cherry picked from commit 8b16a58)
Allows to execute a model function when the job fails and will not be retried. [REF] queue_job: Move on fail definition to job function Rename on_fail_hook to on_fail
This adds `capacity_default` and `sequential_default` options that set `capacity` and `sequential` for autocreated subchannels. It also allows non-root channel configurations to omit capacity.
Job.on_fail_method_name was only set as an instance attribute when the job function configured on_fail_method, so on_fail() raised AttributeError for every job that didn't opt into it.
Updated by "Update PO files to match POT (msgmerge)" hook in Weblate. Translation: queue-18.0/queue-18.0-queue_job Translate-URL: https://translation.odoo-community.org/projects/queue-18-0/queue-18-0-queue_job/
Not used at this point by the jobrunner, but the changes on channels trigger a notify to the jobrunner.
Logging the usage of queue_job__no_delay makes sense only in 'production mode'. We have tons of tests explicitly bypassing jobs and that generates a lot of useless entries in the logs.
Currently translated at 100.0% (158 of 158 strings) Translation: queue-18.0/queue-18.0-queue_job Translate-URL: https://translation.odoo-community.org/projects/queue-18-0/queue-18-0-queue_job/it/
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Sync OCA 18.0 — 2026-09-22
Merges 63 OCA commits into the xipp fork, preserving all 2 xipp-only commits.
Scope
queue_job_profilerValidation