OS cli doesn't handle cinder 503 response

Bug #1629292 reported by Proskurin Kirill
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
python-openstackclient
New
Undecided
Unassigned

Bug Description

$ openstack --version
openstack 3.2.0

vagrant@node1:~$ pip list | fgrep client
ndg-httpsclient (0.4.0)
os-client-config (1.21.1)
python-cinderclient (1.9.0)
python-glanceclient (2.5.0)
python-keystoneclient (3.5.0)
python-neutronclient (6.0.0)
python-novaclient (6.0.0)
python-openstackclient (3.2.0)
websocket-client (0.37.0)

I have a cinder-api missonfigured and it returns:
RESP BODY: {"message": "The server is currently unavailable. Please try again at a later time.<br /><br />\n\n\n", "code": "503 Service Unavailable", "title": "Service Unavailable"}

But OS cli doesn't handle this properly and returns:
AttributeError: 'unicode' object has no attribute 'get'

Full log:
http://paste.openstack.org/show/583615/

Revision history for this message
Steve Martinelli (stevemar) wrote :

What does `cinder list` output? What is the desired/expected behaviour? Given a misconfigured service, there isn't much a client can do to solve the problem. Are you asking for a better error message with no stacktrace?

Revision history for this message
Proskurin Kirill (kproskurin) wrote :

We have a 503 code with message "The server is currently unavailable. Please try again at a later time" and we recive a "AttributeError: 'unicode' object has no attribute 'get'".

From the UX point of view it's really confusing. I think we need to handle this situation and print something like:

"Request failed, error message was:

The server is currently unavailable. Please try again at a later time. HTTP Code: 503"

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.