diff --git a/auditlog/models/rule.py b/auditlog/models/rule.py index 226897746cf..c3b4354e8c1 100644 --- a/auditlog/models/rule.py +++ b/auditlog/models/rule.py @@ -697,9 +697,7 @@ def subscribe(self): act_window_model = self.env["ir.actions.act_window"] for rule in self: # Create a shortcut to view logs - domain = "[('model_id', '=', %s), ('res_id', '=', id)]" % ( - rule.model_id.id - ) + domain = "[('model_id', '=', %s), ('res_id', '=', id)]" % (rule.model_id.id) vals = { "name": _("View logs"), "res_model": "auditlog.log", diff --git a/base_exception/models/exception_rule.py b/base_exception/models/exception_rule.py index 1a51ea6e1ab..dcfdbf3c20b 100644 --- a/base_exception/models/exception_rule.py +++ b/base_exception/models/exception_rule.py @@ -113,9 +113,9 @@ def _to_cache_entry(self): "sequence": self.sequence, "model": self.model, "exception_type": self.exception_type, - "domain": self._get_domain() - if self.exception_type == "by_domain" - else None, + "domain": ( + self._get_domain() if self.exception_type == "by_domain" else None + ), "method": self.method, "code": self.code, "is_blocking": self.is_blocking, diff --git a/database_cleanup/models/purge_properties.py b/database_cleanup/models/purge_properties.py index 3ae76f67ceb..d4d81a6d8b8 100644 --- a/database_cleanup/models/purge_properties.py +++ b/database_cleanup/models/purge_properties.py @@ -103,8 +103,7 @@ def find(self): "id", "not in", default_properties.filtered( - lambda x, - prop_fields_id=prop.fields_id: x.company_id + lambda x, prop_fields_id=prop.fields_id: x.company_id and x.fields_id == prop_fields_id ).ids, ) diff --git a/views_migration_17/patch_xml_import.py b/views_migration_17/patch_xml_import.py index cd5b1472ce6..d6e8452cb84 100644 --- a/views_migration_17/patch_xml_import.py +++ b/views_migration_17/patch_xml_import.py @@ -451,7 +451,6 @@ def convert_inherit_attributes_inplace(spec, target_node, view_type): all_attrs.sort() i = len(all_attrs) - next_xml = "" for attr in all_attrs: value = items.get(attr)