Univention Bugzilla – Bug 52403
remove misleading traceback when creating OUs through UMC
Last modified: 2021-02-10 09:27:41 CET
When creating school object (OUs) through the UMC "Schulen" module, a lot of UDM errors are logged to /v/l/u/management-console-module-schoolwizards.log: ------------------------------------------------------------------ 20.11.20 12:39:56.675 MODULE ( PROCESS ) : Creating Container(name='ucsschool', school='', dn='cn=ucsschool,cn=groups,dc=uni,dc=dtr', old_dn=None) 20.11.20 12:39:56.677 ADMIN ( ERROR ) : Creating 'cn=ucsschool,cn=groups,dc=uni,dc=dtr' failed: Traceback (most recent call last): File "/usr/lib/python2.7/dist-packages/univention/admin/handlers/__init__.py", line 1254, in _create self.lo.add(self.dn, al, serverctrls=serverctrls, response=response) File "/usr/lib/python2.7/dist-packages/univention/admin/uldap.py", line 857, in add raise univention.admin.uexceptions.objectExists(dn) objectExists: cn=ucsschool,cn=groups,dc=uni,dc=dtr ------------------------------------------------------------------ Those tracebacks can be avoided, so the user doesn't get confused and real errors are easier to spot.
A code line was added to ucs-school-lib/python/models/group.py that checks if a container exists, before trying to create it. That prevents the UDM error message. Branch: dtroeder/52403_remove_traceback_when_creating_ou 4d17b5d08 Commit: Bug #52403: don't try to create already existing containers
QA → All OK → Please build and merge Code looks good. Before fix: File "/usr/lib/python2.7/dist-packages/univention/admin/handlers/__init__.py", line 1254, in _create self.lo.add(self.dn, al, serverctrls=serverctrls, response=response) File "/usr/lib/python2.7/dist-packages/univention/admin/uldap.py", line 857, in add raise univention.admin.uexceptions.objectExists(dn) objectExists: cn=ouadmins,cn=groups,dc=wenzel-univention,dc=intranet After fix → no traceback.
Merged and built. [4.4] 5f429d84a Bug #52403: don't try to create already existing containers [4.4] cea08ca81 Bug #52403: Merge branch 'dtroeder/52403_remove_traceback_when_creating_ou' into 4.4 [4.4] e4ce5e9f3 Bug #52403: changelog and advisory [4.4] 16b81a4a6 Bug #52403: advisory update ucs-school-lib (12.2.3)
QA → All OK → VERIFY changelog OK yaml & version OK no merge conflicts OK
Errata updates for UCS@school 4.4 v8 have been released. https://docs.software-univention.de/changelog-ucsschool-4.4v8-de.html If this error occurs again, please clone this bug.