diff --git a/addons/queue_job/migrations/16.0.2.6.1/pre-migration.py b/addons/queue_job/migrations/16.0.2.6.1/pre-migration.py new file mode 100644 index 0000000..53d9690 --- /dev/null +++ b/addons/queue_job/migrations/16.0.2.6.1/pre-migration.py @@ -0,0 +1,10 @@ +# License LGPL-3.0 or later (http://www.gnu.org/licenses/lgpl.html) + +from odoo.tools.sql import table_exists + + +def migrate(cr, version): + if table_exists(cr, "queue_job"): + # Drop index 'queue_job_identity_key_state_partial_index', + # it will be recreated during the update + cr.execute("DROP INDEX IF EXISTS queue_job_identity_key_state_partial_index;")