[BUG]- Odoo version 19 -OpenUpgrade module - psycopg2.errors.DatatypeMismatch: argument of AND must be type boolean, not type character varying

Open
#1,136 2 comments 0 reactions 0 assignees View on GitHub

Maintainers usually reply within 1 day

Nobody has claimed this yet.

Assessment

Difficulty
4/5
Estimated time
3-5 days
Newbie friendliness
22/100
Issue type
Bug
Clarity
Mostly clear
Activity status
Quiet
Tech stack
postgresql, python
Domain
backend, database

Research direction

The traceback points to delete_record_translations in openupgradelib/openupgrade.py around line 2865, where the SQL WHERE clause compares isc.table_name and imf.transl. The filing repo is OCA/reporting-engine, but the failing code lives in the openupgradelib dependency, so check that upstream first. Done means the query runs on PostgreSQL without a DatatypeMismatch on a v18 to v19 migration.

Written by the indexing model from the issue text.

Description

bug stale

Module

OpenUpgrade

Describe the bug

When i Migrated my v18 database in to V19 using openUpgrade moduel and normally run the scripts
getting error from delete_record_translations like below:

File "/home/odoo/.virtualenvs/odoo_venv/lib/python3.12/site-packages/openupgradelib/openupgrade.py", line 2865, in delete_record_translations
cr.execute(
File "/home/odoo/Workplace/odoo/19/odoo/odoo/sql_db.py", line 433, in execute
self._obj.execute(query, params)
psycopg2.errors.DatatypeMismatch: argument of AND must be type boolean, not type character varying
LINE 6: ... WHERE isc.table_name = 'mail_template' AND imf.transl.

To Reproduce

Affected versions: 19.0

Steps to reproduce the behavior:

  1. Create V18 database and migrate in to v19
Dominant language
HTML
Stars
435
Forks
929
Avg merge
6d 18h
Merged PRs (30d)
2

Getting set up

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from OCA/reporting-engine

All issues in OCA/reporting-engine

Similar issues

More Backend & API Design issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.