glanceclient.common.utils.strip_version doesn't handle a service type in the path

Bug #1748009 reported by Matt Riedemann
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Glance Client
In Progress
Cyril Roelandt

Bug Description

In trying to workaround bug 1707995, where we have a URL like:

We tried using glanceclient.common.utils.strip_version() but that doesn't work with the 'image' in the path:

>>> from glanceclient.common import utils
>>> url = ''
>>> utils.strip_version(url)
('', None)
>>> url = ''
>>> url_parts = urlparse.urlparse(url)
>>> url_parts
ParseResult(scheme='http', netloc='', path='/v2', params='', query='', fragment='')
>>> utils.strip_version(url)
('', 2.0)

Changed in python-glanceclient:
status: New → Triaged
assignee: nobody → Abhishek Kekane (abhishek-kekane)
Changed in python-glanceclient:
assignee: Abhishek Kekane (abhishek-kekane) → Cyril Roelandt (cyril-roelandt)
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to python-glanceclient (master)
Changed in python-glanceclient:
status: Triaged → In Progress
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.