Univention Bugzilla – Bug 49235
Remove unnecessary default values in univention.admin.property descriptions
Last modified: 2019-05-15 14:52:25 CEST
It would save a lot of space if we remove all parameters which equal the default value in the definition of the univention.admin.propertiy() calls in each UDM handler.
Fixed in branch: <https://git.knut.univention.de/univention/ucs/commits/phahn/49235-udm-default-properties?utf8=%E2%9C%93&search=Bug+%2349235> 109 files changed, 17 insertions(+), 3812 deletions(-) Reopen to merge.
Created attachment 9965 [details] Script to drop default values of properties
removing options=[] causes that every property has the same list instance. I think we should add something like: self.options = options[:] into propterty.__init__().
Otherwise everything looks great, you can merge it after comment #3 then.
[4.4-0] 000aca283e Bug #46466: univention-directory-manager-modules 14.0.12-25A~4.4.0.201904182018 doc/errata/staging/univention-directory-manager-modules.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) [4.4-0] 131d8e26b3 Bug #49235 udm: Remove default values of properties Package: univention-directory-manager-modules Version: 14.0.12-25A~4.4.0.201904182018 Branch: ucs_4.4-0 Scope: errata4.4-0 (In reply to Florian Best from comment #3) > removing options=[] causes that every property has the same list instance. I > think we should add something like: > self.options = options[:] into propterty.__init__(). Good catch; I changed it slightly differently and I'm using self.options = options or [] self.licence = licence or [] which only instantiates a list if the passed-in (default) list is empty.
[4.4-0] 131d8e26b3 Bug #49235 udm: Remove default values of properties [4.4-0] 6423bbd411 Bug #49235 udm: Remove default values of properties [4.4-0] bfeffd196e Bug #49235 udm: Drop default property copyable=False|0 [4.4-0] 1ca8f5a32f Bug #49235 udm: Drop default property readonly_when_synced=False|0 [4.4-0] 09ef5159ef Bug #49235 udm: Drop default property include_in_default_search=False|0 [4.4-0] 20ec93a667 Bug #49235 udm: Drop default property editable=True|1 [4.4-0] 279bf4efef Bug #49235 udm: Drop default property show_in_lists=False|0 [4.4-0] b548cb8100 Bug #49235 udm: Drop default property dontsearch=False|0 [4.4-0] 0a92e273f7 Bug #49235 udm: Drop default property default=None [4.4-0] 18d5b22abd Bug #49235 udm: Drop default property identifies=False|0 [4.4-0] cf70e966d9 Bug #49235 udm: Drop default property may_change=True|1 [4.4-0] 77f9f6232f Bug #49235 udm: Drop default property required=False|0 [4.4-0] 430fc5f472 Bug #49235 udm: Drop default property options=\[\] [4.4-0] 2746a80b10 Bug #49235 udm: Unshare list for options and license [4.4-0] f2063323f1 Bug #49235 udm: Drop default property multivalue=False|0 Package: univention-directory-manager-modules Version: 14.0.12-25A~4.4.0.201904182018 Branch: ucs_4.4-0 Scope: errata4.4-0 [4.4-0] 763efd6990 Bug #49235: univention-directory-manager-modules 14.0.12-25A~4.4.0.201904182018 doc/errata/staging/univention-directory-manager-modules.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
OK
[FAIL] changes.valid: Mismatching binary package version: 14.0.12-25A~4.4.0.201904182018 != python-univention-directory-manager-cli 14.0.12-27A~4.4.0.201904301002 from univention-directory-manager-modules 14.0.12-27A~4.4.0.201904301002
That's caused by Bug 48390.
<http://errata.software-univention.de/ucs/4.4/102.html>