Bug 1234301

Summary: Error causes image creation window to loose values
Product: Red Hat OpenStack Reporter: lkuchlan <lkuchlan>
Component: python-django-horizonAssignee: Jason E. Rist <jrist>
Status: CLOSED ERRATA QA Contact: Ido Ovadia <iovadia>
Severity: low Docs Contact:
Priority: medium    
Version: 7.0 (Kilo)CC: aortega, athomas, dtrainor, jschluet, mrunge, rdopiera, srevivo
Target Milestone: gaKeywords: Triaged
Target Release: 10.0 (Newton)   
Hardware: x86_64   
OS: Linux   
Whiteboard:
Fixed In Version: python-django-horizon-10.0.0-0.20161002185148.3252153.4.el7ost Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2016-12-14 15:12:59 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Attachments:
Description Flags
log none

Description lkuchlan 2015-06-22 10:24:17 UTC
Created attachment 1041708 [details]
log

Description of problem:
In 'Create An Image' widow, when inserting an illegal URL in image location field, the action fails and the image format field looses its content        

Version-Release number of selected component (if applicable):
python-django-horizon-2015.1.0-10.el7ost.noarch

How reproducible:
sometimes 

Steps to Reproduce:
1. From 'Create An Image' window, insert an illegal URL in image location field 
2. Try to confirm the creation image

Actual results:
The format field is not configured, although it was 

Expected results:
The format field should stay as it was configured 

Additional info:

From horizon log:
[Mon Jun 22 09:19:12.758853 2015] [:error] [pid 21067]   File "/usr/share/openstack-dashboard/openstack_dashboard/wsgi/../../openstack_dashboard/api/glance.py", line 129, in image_update
[Mon Jun 22 09:19:12.758997 2015] [:error] [pid 21067]     return image
[Mon Jun 22 09:19:12.759045 2015] [:error] [pid 21067] UnboundLocalError: local variable 'image' referenced before assignment
[Mon Jun 22 09:19:33.647517 2015] [:error] [pid 21068] Unhandled exception in thread started by <function image_update at 0x7fd151ff0320>
[Mon Jun 22 09:19:33.655274 2015] [:error] [pid 21068] Traceback (most recent call last):
[Mon Jun 22 09:19:33.655319 2015] [:error] [pid 21068]   File "/usr/share/openstack-dashboard/openstack_dashboard/wsgi/../../openstack_dashboard/api/glance.py", line 129, in image_update
[Mon Jun 22 09:19:33.655379 2015] [:error] [pid 21068]     return image
[Mon Jun 22 09:19:33.655418 2015] [:error] [pid 21068] UnboundLocalError: local variable 'image' referenced before assignment
[Mon Jun 22 09:20:07.599046 2015] [:error] [pid 21069] Unhandled exception in thread started by <function image_update at 0x7fd151ff0320>
[Mon Jun 22 09:20:07.606163 2015] [:error] [pid 21069] Traceback (most recent call last):
[Mon Jun 22 09:20:07.606205 2015] [:error] [pid 21069]   File "/usr/share/openstack-dashboard/openstack_dashboard/wsgi/../../openstack_dashboard/api/glance.py", line 129, in image_update
[Mon Jun 22 09:20:07.606293 2015] [:error] [pid 21069]     return image
[Mon Jun 22 09:20:07.606336 2015] [:error] [pid 21069] UnboundLocalError: local variable 'image' referenced before assignment
[Mon Jun 22 09:21:05.728746 2015] [:error] [pid 21069] Unhandled exception in thread started by <function image_update at 0x7fd151ff0320>
[Mon Jun 22 09:21:05.728826 2015] [:error] [pid 21069] Traceback (most recent call last):
[Mon Jun 22 09:21:05.728846 2015] [:error] [pid 21069]   File "/usr/share/openstack-dashboard/openstack_dashboard/wsgi/../../openstack_dashboard/api/glance.py", line 129, in image_update
[Mon Jun 22 09:21:05.728923 2015] [:error] [pid 21069]     return image
[Mon Jun 22 09:21:05.728972 2015] [:error] [pid 21069] UnboundLocalError: local variable 'image' referenced before assignment
[Mon Jun 22 09:21:26.640919 2015] [:error] [pid 21069] Unhandled exception in thread started by <function image_update at 0x7fd151ff0320>
[Mon Jun 22 09:21:26.640967 2015] [:error] [pid 21069] Traceback (most recent call last):
[Mon Jun 22 09:21:26.640990 2015] [:error] [pid 21069]   File "/usr/share/openstack-dashboard/openstack_dashboard/wsgi/../../openstack_dashboard/api/glance.py", line 129, in image_update
[Mon Jun 22 09:21:26.641080 2015] [:error] [pid 21069]     return image
[Mon Jun 22 09:21:26.641123 2015] [:error] [pid 21069] UnboundLocalError: local variable 'image' referenced before assignment
(END)

Comment 5 Itxaka 2016-04-25 10:02:23 UTC
This seems to have been fixed on 8 and backported to 7 upstream as per the attached launchpad

Comment 6 Itxaka 2016-04-25 10:07:54 UTC
This should be fixed on the updated packages, at least on python-django-horizon-2015.1.1-0.el7ost.noarch.rpm

Can you update and try to reproduce?

Comment 8 Radomir Dopieralski 2016-10-20 11:42:21 UTC
This is already fixed in osp10.

Comment 12 Dan Trainor 2016-12-09 20:45:22 UTC
Upstream 1467462 was a duplicate of upstream 1464991

Comment 13 Dan Trainor 2016-12-09 21:22:33 UTC
The "Format" field stays as it was configured when an image is created with bad values.

Comment 15 errata-xmlrpc 2016-12-14 15:12:59 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://rhn.redhat.com/errata/RHEA-2016-2948.html