[Erp5-dev] Patches to make XML representation of BT more stable
Julien Muchembled
jm at nexedi.com
Wed Aug 27 17:22:42 CEST 2008
Hello,
Business Templates and ERP5 Subversion are very unfriendly because of several problems:
* wrong and unstable indentation
* several useless attributes appear and disappear
* dynamic data for certain meta types:
* Z SQL Methods: 'template' attribute (containing a copy of the source)
* Script (Python): func_code & func_defaults
Here are a few patches fixing them:
* 01_bt_indentation.patch
This fixes the problem related to indendation.
Indentation spaces mustn't be kept in cache (Immutable).
* 02_bt_common_attr.patch
Really remove '_filepath', '_owner', 'uid' and '__ac_local_roles__' attributes instead of setting to None when they are defined on the object.
Both 01_bt_indentation and 02_bt_common_attr patches are backward & forward compatible.
* 03_bt_ZSQLMethod.patch (to apply after 02_bt_common_attr.patch)
Remove the 'template' property. It must be computed again on import.
* 04_bt_PythonScript.patch (to apply after 03_bt_ZSQLMethod.patch)
Remove func_code & func_defaults. Really remove the '_code' attribute.
The script must always be recompiled on import.
For unit tests, I had to rewrite the mechanism of lazy compilation.
03_bt_ZSQLMethod.patch and 04_bt_PythonScript.patch are backward compatible but not forward compatible.
(This means that old code won't be able to import cleaned BT)
Patches have tested and I am ready to apply them.
However, this means that everybody should update their product at the same time.
Julien Muchembled
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: 01_bt_indentation.patch
URL: <http://mail.tiolive.com/pipermail/erp5-dev/attachments/20080827/7ec354a6/attachment.asc>
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: 02_bt_common_attr.patch
URL: <http://mail.tiolive.com/pipermail/erp5-dev/attachments/20080827/7ec354a6/attachment.txt>
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: 03_bt_ZSQLMethod.patch
URL: <http://mail.tiolive.com/pipermail/erp5-dev/attachments/20080827/7ec354a6/attachment-0001.asc>
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: 04_bt_PythonScript.patch
URL: <http://mail.tiolive.com/pipermail/erp5-dev/attachments/20080827/7ec354a6/attachment-0001.txt>
More information about the Erp5-dev
mailing list