Bug 41717 - ucs-school user without school breaks UMC-users-wizard
ucs-school user without school breaks UMC-users-wizard
Status: CLOSED DUPLICATE of bug 42441
Product: UCS@school
Classification: Unclassified
Component: Ucsschool-lib
UCS@school 4.1 R2
Other Linux
: P5 normal (vote)
: ---
Assigned To: UCS@school maintainers
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2016-07-01 15:57 CEST by Daniel Tröder
Modified: 2023-06-12 15:39 CEST (History)
1 user (show)

See Also:
What kind of report is it?: Bug Report
What type of bug is this?: 3: Simply Wrong: The implementation doesn't match the docu
Who will be affected by this bug?: 2: Will only affect a few installed domains
How will those affected feel about the bug?: 1: Nuisance – not a big deal but noticeable
User Pain: 0.034
Enterprise Customer affected?:
School Customer affected?:
ISV affected?:
Waiting Support:
Flags outvoted (downgraded) after PO Review:
Ticket number:
Bug group (optional):
Max CVSS v3 score:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Daniel Tröder univentionstaff 2016-07-01 15:57:40 CEST
If the last school of a User is removed, the UMC-users-wizard cannot edit any user at all anymore.

Reproduce:

1. create student
2. edit student -> adv. settings -> UCS@school tab -> remove all school(s)
3. save
4. optional: try to readd school to user
5. optional: delete the user
6. try to edit and save any other user im UMC-wizard -> stacktrace:

Die Ausführung des Kommandos schoolwizards/users/put schoolwizards/users ist fehlgeschlagen:

Traceback (most recent call last):
  File "/usr/lib/pymodules/python2.7/univention/management/console/base.py", line 283, in execute
    function(self, request)
  File "/usr/lib/pymodules/python2.7/univention/management/console/modules/schoolwizards/__init__.py", line 112, in _decorated
    ret = func(self, request, *a, **kw)
  File "/usr/lib/pymodules/python2.7/ucsschool/lib/schoolldap.py", line 140, in wrapper_func
    return func(*args, **kwargs)
  File "/usr/lib/pymodules/python2.7/univention/management/console/modules/schoolwizards/__init__.py", line 204, in _modify_obj
    obj.modify(ldap_user_write, validate=False)
  File "/usr/lib/pymodules/python2.7/ucsschool/lib/models/base.py", line 471, in modify
    success = self.modify_without_hooks(lo, validate, move_if_necessary)
  File "/usr/lib/pymodules/python2.7/ucsschool/lib/models/base.py", line 494, in modify_without_hooks
    self.do_modify(udm_obj, lo)
  File "/usr/lib/pymodules/python2.7/ucsschool/lib/models/user.py", line 256, in do_modify
    mandatory_groups = self.groups_used(lo)
  File "/usr/lib/pymodules/python2.7/ucsschool/lib/models/user.py", line 447, in groups_used
    group_dns = self.get_specific_groups(lo)
  File "/usr/lib/pymodules/python2.7/ucsschool/lib/models/user.py", line 574, in get_specific_groups
    groups = super(Student, self).get_specific_groups(lo)
  File "/usr/lib/pymodules/python2.7/ucsschool/lib/models/user.py", line 349, in get_specific_groups
    groups = self.get_domain_users_groups()
  File "/usr/lib/pymodules/python2.7/ucsschool/lib/models/user.py", line 432, in get_domain_users_groups
    return [self.get_group_dn('Domain Users %s' % school, school) for school in self.schools]
TypeError: 'NoneType' object is not iterable
Comment 1 Florian Best univentionstaff 2016-10-25 15:59:55 CEST
Should be fixed with Bug #42441 (not completely sure).

*** This bug has been marked as a duplicate of bug 42441 ***