Univention Bugzilla – Bug 39581
UnboundLocalError: local variable 'username' referenced before assignment
Last modified: 2015-11-17 12:11:58 CET
I saw the following traceback in ucs-test on a S3 DC Backup. http://jenkins.knut.univention.de:8080/job/UCS-4.1/job/UCS-4.1-0/job/Autotest%20MultiEnv/SambaVersion=s3,Systemrolle=backup/66/testReport/80_docker/55_app_modproxy/test/ Status: Image is up to date for docker.software-univention.de/ucs-appbox-amd64:4.1-0 Initializing app image Preconfiguring container fd8f93a6ec7138dba1057a289c4589d584a989045eed267bebd2b6e615eeb816 Error response from daemon: Cannot restart container fd8f93a6ec7138dba1057a289c4589d584a989045eed267bebd2b6e615eeb816: Bind for 0.0.0.0:40001 failed: port is already allocated time="2015-10-18T21:15:18-04:00" level=fatal msg="Error: failed to restart one or more containers" Starting sr3akmzo3a Container fd8f93a6ec7138dba1057a289c4589d584a989045eed267bebd2b6e615eeb816 ... Unable to start the container! Aborting... Going to remove sr3akmzo3a (5.3.9) Invalid credentials File: /usr/share/univention-management-console/modules/apps.xml File: /usr/share/univention-management-console/i18n/de/apps.mo File: /etc/apt/apt.conf.d/55user_agent Downloading "https://backup092.autotest092.local/meta-inf/categories.ini"... Downloading "https://backup092.autotest092.local/meta-inf/4.1/index.json.gz"... 0 file(s) are new sr3akmzo3a=5.3.9: Not running, cannot check further local variable 'username' referenced before assignment Traceback (most recent call last): File "/usr/lib/pymodules/python2.7/univention/appcenter/actions/__init__.py", line 182, in call_with_namespace result = self.main(namespace) File "/usr/lib/pymodules/python2.7/univention/appcenter/actions/remove.py", line 46, in main self.do_it(args) File "/usr/lib/pymodules/python2.7/univention/appcenter/actions/install_base.py", line 106, in do_it self._do_it(app, args) File "/usr/lib/pymodules/python2.7/univention/appcenter/actions/docker_remove.py", line 47, in _do_it self._unregister_host(app, args) File "/usr/lib/pymodules/python2.7/univention/appcenter/actions/register.py", line 245, in _unregister_host lo, pos = self._get_ldap_connection(args) File "/usr/lib/pymodules/python2.7/univention/appcenter/actions/credentials.py", line 165, in _get_ldap_connection userdn = self._get_userdn(args) File "/usr/lib/pymodules/python2.7/univention/appcenter/actions/credentials.py", line 108, in _get_userdn username = self._get_username(args) File "/usr/lib/pymodules/python2.7/univention/appcenter/actions/credentials.py", line 74, in _get_username return username UnboundLocalError: local variable 'username' referenced before assignment
Fixed in univention-management-console-module-appcenter 5.0.6-30.477.201510191057
OK, looks better now: http://jenkins.knut.univention.de:8080/job/UCS-4.1/job/UCS-4.1-0/job/Autotest%20MultiEnv/SambaVersion=s3,Systemrolle=backup/80/testReport/80_docker/55_app_modproxy/test/
UCS 4.1 has been released: https://docs.software-univention.de/release-notes-4.1-0-en.html https://docs.software-univention.de/release-notes-4.1-0-de.html If this error occurs again, please use "Clone This Bug".