Import urlutils to substitute urllib

Use the openstack common urlutils.

Partial Implement: blueprint py33-support

Change-Id: I45f21d7316fe87952e841004d4c25999138a842b
This commit is contained in:
Kui Shi
2013-10-14 17:03:29 +08:00
parent 38e1ee4632
commit d70bb3e4e7

View File

@@ -11,8 +11,8 @@
# License for the specific language governing permissions and limitations
# under the License.
from ceilometerclient.openstack.common.py3kcompat import urlutils
import re
import urllib
def build_url(path, q, params=None):
@@ -34,7 +34,7 @@ def build_url(path, q, params=None):
for name in ['field', 'op', 'value']:
query_params['q.%s' % name].append(query.get(name, ''))
path += "?" + urllib.urlencode(query_params, doseq=True)
path += "?" + urlutils.urlencode(query_params, doseq=True)
if params:
for p in params: