Force Swift CLI to provide region info or interrupt the request

Bug #1506383 reported by Hugo Kou
26
This bug affects 4 people
Affects Status Importance Assigned to Milestone
python-swiftclient
Fix Committed
Undecided
Tim Burke

Bug Description

Not sure about if this should be a bug or new feature

In python-keystoneclient 1.7.0+ , it mentioned

```
/app/python3/3.4.3/lib/python3.4/site-packages/keystoneclient/service_catalog.py:196: UserWarning: Providing attr without filter_value to get_urls() is deprecated as of the 1.7.0 release and may be removed in the 2.0.0 release. Either both should be provided or neither should be provided.

'Providing attr without filter_value to get_urls() is '
```

https://github.com/openstack/python-keystoneclient/commit/0d293eaf4413f82f55e3b13062b2bc710a6f3935

```
- # TODO(jamielennox): at least swiftclient is known to set attr and not
- # filter_value and expects that to mean that filtering is ignored, so
- # we can't check for the presence of attr. This behaviour should be
- # deprecated and an appropriate warning provided.
+ if attr and not filter_value:
+ warnings.warn(
+ 'Providing attr without filter_value to get_urls() is '
+ 'deprecated as of the 1.7.0 release and may be removed in the '
+ '2.0.0 release. Either both should be provided or neither '
+ 'should be provided.')
+
```

python-swiftclient should force user to provide region name if python-keystoneclient is 1.7.0+

Hugo Kou (tonytkdk)
Changed in swift:
assignee: nobody → Hugo Kou (tonytkdk)
Revision history for this message
Hugo Kou (tonytkdk) wrote :

1. To interrupt the request if auth version > 2.0 and force user to provide region name in the request
2. To allow the request but shows up a more clear reason about why
3. To give a default region name

Changed in swift:
assignee: Hugo Kou (tonytkdk) → nobody
renminmin (rmm0811)
affects: swift → python-swiftclient
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Change abandoned on python-swiftclient (master)

Change abandoned by renminmin (<email address hidden>) on branch: master
Review: https://review.openstack.org/259887

Revision history for this message
OpenStack Infra (hudson-openstack) wrote :

Change abandoned by renminmin (<email address hidden>) on branch: master
Review: https://review.openstack.org/259879

Revision history for this message
Tim Burke (1-tim-z) wrote :
Changed in python-swiftclient:
assignee: nobody → Tim Burke (1-tim-z)
status: New → Fix Committed
Revision history for this message
Hugo Kou (tonytkdk) wrote :
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Duplicates of this bug

Other bug subscribers

Remote bug watches

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