Bug 48518 - Can't edit school computers
Can't edit school computers
Status: RESOLVED WONTFIX
Product: UCS@school
Classification: Unclassified
Component: Ucsschool-lib
UCS@school 4.4
Other Linux
: P5 normal (vote)
: ---
Assigned To: UCS@school maintainers
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2019-01-23 11:08 CET by Jürn Brodersen
Modified: 2023-06-23 13:01 CEST (History)
3 users (show)

See Also:
What kind of report is it?: Development Internal
What type of bug is this?: ---
Who will be affected by this bug?: ---
How will those affected feel about the bug?: ---
User Pain:
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 Jürn Brodersen univentionstaff 2019-01-23 11:08:50 CET
Can't edit school computers

How to reproduce:
Add a school computer -> Save -> Edit e.g by adding an inventory number

This might be a problem in 4.3 with roles enabled as well.

Internal server error during "schoolwizards/computers/put (schoolwizards/computers)".
Request: schoolwizards/computers/put (schoolwizards/computers)

Traceback (most recent call last):
  File "/usr/lib/pymodules/python2.7/univention/management/console/base.py", line 253, in execute
    function.__func__(self, request, *args, **kwargs)
  File "/usr/lib/pymodules/python2.7/univention/management/console/modules/decorators.py", line 192, in _response
    return function(self, request)
  File "/usr/lib/pymodules/python2.7/univention/management/console/modules/schoolwizards/__init__.py", line 122, in _decorated
    ret = func(self, request, *a, **kw)
  File "/usr/lib/pymodules/python2.7/ucsschool/lib/schoolldap.py", line 145, in wrapper_func
    return func(*args, **kwargs)
  File "/usr/lib/pymodules/python2.7/univention/management/console/modules/schoolwizards/__init__.py", line 235, in _modify_obj
    obj.modify(ldap_user_write, validate=False)
  File "/usr/lib/pymodules/python2.7/ucsschool/lib/models/base.py", line 518, in modify
    success = self.modify_without_hooks(lo, validate, move_if_necessary)
  File "/usr/lib/pymodules/python2.7/ucsschool/lib/models/computer.py", line 220, in modify_without_hooks
    return super(SchoolComputer, self).modify_without_hooks(lo, validate, move_if_necessary)
  File "/usr/lib/pymodules/python2.7/ucsschool/lib/models/base.py", line 541, in modify_without_hooks
    self.modify_without_hooks_roles(udm_obj)
  File "/usr/lib/pymodules/python2.7/ucsschool/lib/models/base.py", line 1080, in modify_without_hooks_roles
    old_schools = set(self.get_schools_from_udm_obj(udm_obj))
  File "/usr/lib/pymodules/python2.7/ucsschool/lib/models/base.py", line 1014, in get_schools_from_udm_obj
    return udm_obj.info['school']
KeyError: 'school'
Comment 1 Jürn Brodersen univentionstaff 2019-01-23 11:19:05 CET
This might have been introduced in bug 48226.
Comment 2 Daniel Tröder univentionstaff 2019-02-13 13:16:27 CET
I cannot reproduce this (anymore?).
Comment 3 Jan-Luca Kiok univentionstaff 2023-06-23 13:01:52 CEST
This issue has been filed against UCS 4.4.

UCS 4.4 is out of maintenance and UCS components may have vastly changed in later releases. Thus, this issue is now being closed.

If this issue still occurs in newer UCS versions, please use "Clone this bug" or reopen this issue. In this case please provide detailed information on how this issue is affecting you.