With the release of Odoo 19.0, several changes were introduced to the XML view engine. One of the most impactful adjustments relates to the <group> tag in search views. If you’ve recently upgraded, you may have encountered the dreaded error:
View error context: -no context-
Enter fullscreen mode Exit fullscreen mode
This error is directly tied to deprecated properties inside <group> tags.
❌ What Changed?
In earlier versions of Odoo, developers often used <group> with properties such as:
<group expand="0" string="Group By">
<filter name="user_id" string="User" context="{'group_by': 'user_id'}"/>
</group>
Enter fullscreen mode Exit fullscreen mode
However, starting from Odoo 19.0, the following attributes are no longer supported:
-
expand="0" -
name="group_by" string="Group By"
✅ How to Fix It
You should remove the unsupported properties and keep only the valid <filter> definitions inside <group>. For example:
Old (pre-19.0)
<group expand="0" string="Group By">
<filter name="user_id" string="User" context="{'group_by': 'user_id'}"/>
</group>
Enter fullscreen mode Exit fullscreen mode
New (19.0+)
<group>
<filter name="user_id" string="User" context="{'group_by': 'user_id'}"/>
</group>
Enter fullscreen mode Exit fullscreen mode
🛠 Migration Checklist
-
Search your codebase for
<group>tags which has such attributes in XML views. -
Remove deprecated attributes (
expand,name,string).
📌 Conclusion
This change may seem minor, but it’s crucial for a smooth migration to Odoo 19.0. By cleaning up your XML views and removing deprecated <group> properties, you’ll avoid runtime errors and ensure compatibility with the view engine.
답글 남기기