-
Notifications
You must be signed in to change notification settings - Fork 51
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[FIX] fields: Handle invalid domains #5
base: master
Are you sure you want to change the base?
Conversation
src/util/fields.py
Outdated
context = safe_eval(context_s or "{}", SelfPrintEvalContext(), nocopy=True) | ||
except SyntaxError: | ||
cr.execute("DELETE FROM ir_filters WHERE id = %s", [id_]) | ||
add_to_migration_reports(("ir.filters", id_, name), "Filters/Dashboards") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The report actually says that the filter has been corrected.
It also adds a 404 link to the removed record.
Also, why removing the filter? I would simply skip it (with a logger.warning
).
src/util/fields.py
Outdated
try: | ||
context = safe_eval(context_s or "{}", SelfPrintEvalContext(), nocopy=True) | ||
except SyntaxError: | ||
cr.execute("DELETE FROM ir_filters WHERE id = %s", [id_]) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
cr.execute("DELETE FROM ir_filters WHERE id = %s", [id_]) | |
cr.execute("DELETE FROM ir_filters WHERE id = %s", [id_]) |
Don't your editor automatically remove the trailing spaces?
@robodoo check |
I'm sorry, @xmo-odoo. I'm afraid I can't do that. |
@nseinlet I didn't know about this PR and had to retrieve its information, you may have to re-approve it as I didn't see previous commands. |
Some filters are simply invalid, and leads to a traceback when removing fields in them.
717cd3f
to
d1c83e4
Compare
upgradeci retry with always only hr project stock |
Some filters are simply invalid, and leads to a traceback when removing fields in them.