error message shows redundant information

Bug #1598714 reported by Bhagyashri Shewale on 2016-07-04
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Glance Client
Jaspreet Singh Rawel

Bug Description

As of now when any api fails, it shows error code twice in the error message.

For Example:
Following error message will be displayed for non existing image:

$ glance image-show <non-existing-image-id>

Error message:
404 Not Found: No image found with ID <non-existing-image-id> (HTTP 404)

In this case 404 is shown twice.

Changed in python-glanceclient:
assignee: nobody → Bhagyashri Shewale (bhagyashri-shewale)

root@controller:/home/ubuntu# glance --version
root@controller:/home/ubuntu# glance image-list
| ID | Name |
| a109d73c-331f-4b30-b2f0-36cda7875560 | cirros |
root@controller:/home/ubuntu# glance image-show a109d73c-331f-4b30-b2f0-36cda7875561
404 Not Found: No image found with ID a109d73c-331f-4b30-b2f0-36cda7875561 (HTTP 404)

Changed in python-glanceclient:
status: New → Incomplete
status: Incomplete → Confirmed
Changed in python-glanceclient:
assignee: Bhagyashri Shewale (bhagyashri-shewale) → Jaspreet Singh Rawel (jaspreetsinghrawel)

Fix proposed to branch: master

Changed in python-glanceclient:
status: Confirmed → In Progress
description: updated

Change abandoned by Brian Rosmaita (<email address hidden>) on branch: master
Reason: Abandoning as a duplicate (other patch is actually older).

Brian Rosmaita (brian-rosmaita) wrote :

Could someone explain why this is a bug? I'm worried about a client relying on parsing the output looking for '(HTTP xxx)'. The error code is mentioned twice, but so what? I need convincing that this change will actually do some good, because it's clear that it could break some clients.

Submitter: Zuul
Branch: master

commit ae4355be01c0b4bcf5b6bdd2c1163b3f6df3e213
Author: bhagyashris <email address hidden>
Date: Thu Jun 30 18:34:14 2016 +0530

    Remove redundant information from error message

    Currently user get redundant HTTP error code in error message.
    Removed redundant HTTP error code from the message.

    For Example:
    Error message display when user trying to get the non existing image:
    $ glance image-show f433471a-53a8-4d31-bf8f-f0b6b594dfc
    Error message:
    404 Not Found: No image found with ID f433471a-53a8-4d31-bf8f-f0b6b594dfc (HTTP 404)

    After this fix:
    HTTP 404 Not Found: No image found with ID f433471a-53a8-4d31-bf8f-f0b6b594dfc

    Closes-Bug: #1598714
    Change-Id: I33971a2a16416c8538158299325471c2a69dbb3e

Changed in python-glanceclient:
status: In Progress → Fix Released

This issue was fixed in the openstack/python-glanceclient 2.16.0 release.

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

Other bug subscribers