Skip to content

Warning: unsupported operand type(s) for "==" in account.financial.report.column onchange #1421

@asharafk9

Description

@asharafk9

module: account_financial_report
version: 16.0.1.16.1

Steps to reproduce
-When opening the General Ledger report via Accounting → OCA Accounting Reports → General Ledger, Python raises the following warning:

Current behavior
Multiple warnings appear in the server log:
UserWarning: unsupported operand type(s) for "==": 'account.financial.report.column()' == '<Command.UPDATE: 1>'
UserWarning: unsupported operand type(s) for "==": 'account.financial.report.column()' == '<Command.LINK: 4>'
UserWarning: unsupported operand type(s) for "==": 'account.financial.report.column()' == '<Command.SET: 6>'

Expected behavior

When opening Accounting → OCA Accounting Reports → General Ledger, the report should trigger the onchange without any warnings in the server log.

The onchange should correctly handle One2many/Many2many relational field commands (Command.UPDATE, Command.LINK, Command.SET) using proper command tuples.

There should be no comparison between a record instance and a Command enum.

All updates to relational fields in the report should work predictably and consistently, without causing potential data inconsistencie

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions