filter doesn't handle unicode charaters
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Glance Client |
Invalid
|
Medium
|
Unassigned | ||
OpenStack Compute (nova) |
Fix Released
|
Medium
|
Richard Jones | ||
OpenStack Dashboard (Horizon) |
Invalid
|
High
|
Unassigned | ||
python-novaclient |
Fix Released
|
Medium
|
Richard Jones |
Bug Description
1 go to project/instances
2. insert 'ölk' into filter field
3. enter filter
4.
UnicodeEncodeError at /project/instances/
'ascii' codec can't encode character u'\xf6' in position 0: ordinal not in range(128)
Request Method: GET
Request URL: http://
Django Version: 1.8.2
Exception Type: UnicodeEncodeError
Exception Value:
'ascii' codec can't encode character u'\xf6' in position 0: ordinal not in range(128)
Exception Location: /usr/lib64/
Python Executable: /usr/bin/python
Python Version: 2.7.10
Python Path:
['/home/
'/usr/
'/usr/
'/usr/
'/usr/
'/usr/
'/usr/
'/usr/
'/usr/
'/usr/
'/home/
Changed in horizon: | |
importance: | Undecided → High |
Changed in horizon: | |
assignee: | nobody → Ritesh (rsritesh) |
status: | New → Confirmed |
tags: | added: api db string-encoding |
Changed in nova: | |
assignee: | nobody → George Peristerakis (george-peristerakis) |
affects: | nova → python-novaclient |
Changed in python-novaclient: | |
assignee: | George Peristerakis (george-peristerakis) → nobody |
status: | New → In Progress |
assignee: | nobody → George Peristerakis (george-peristerakis) |
Changed in horizon: | |
milestone: | none → liberty-rc1 |
Changed in nova: | |
status: | New → In Progress |
Changed in horizon: | |
milestone: | liberty-rc1 → next |
Changed in python-novaclient: | |
importance: | Undecided → Medium |
Changed in nova: | |
importance: | Undecided → Medium |
Changed in horizon: | |
status: | In Progress → Invalid |
Changed in nova: | |
status: | In Progress → Fix Committed |
Changed in python-novaclient: | |
status: | In Progress → Fix Committed |
Changed in python-glanceclient: | |
importance: | Undecided → Medium |
Changed in python-glanceclient: | |
milestone: | none → 1.1.1 |
Changed in python-novaclient: | |
milestone: | none → 2.32.0 |
status: | Fix Committed → Fix Released |
Changed in horizon: | |
assignee: | Masco (masco) → nobody |
Changed in nova: | |
status: | Fix Committed → Fix Released |
Changed in horizon: | |
milestone: | next → none |
there seems to be two problems
1) horizon does not encode unicode string before setting it into url param v2/servers. py: 593
query_ string = "?%s" % parse.urlencode (new_qparams)
novaclient/
it should encode unicode string to utf-8 before urlencode
2) but even encoding it to utf-8 , nova api cant handle it (500 error happen at api call)
2015-07-10 11:20:33.035 ERROR nova.api.openstack [req-2e7f9436- fa14-4b84- 95cb-4f21e423d9 aa admin admin] Caught error: 'ascii' codec can't encode characters in position 0-1: ordinal not in range(128) nova/nova/ api/openstack/ __init_ _.py", line 126, in __call__ response( self.applicatio n) lib/python2. 7/dist- packages/ webob/request. py", line 1317, in send info=False) lib/python2. 7/dist- packages/ webob/request. py", line 1281, in call_application self.environ, start_response) lib/python2. 7/dist- packages/ webob/dec. py", line 144, in __call__ lib/python2. 7/dist- packages/ webob/dec. py", line 130, in __call__ lib/python2. 7/dist- packages/ webob/dec. py", line 195, in call_func lib/python2. 7/dist- packages/ keystonemiddlew are/auth_ token/_ _init__ .py", line 434, in __call__ response( self._app) lib/python2. 7/dist- packages/ webob/request. py", line 1317, in send info=False) lib/python2. 7/dist- packages/ webob/request. py", line 1281, in call_application self.environ, start_response) lib/python2. 7/dist- packages/ webob/dec. py", line 144, in __call__ lib/python2. 7/dist- packages/ webob/dec. py", line 144, in __call__
2015-07-10 11:20:33.035 TRACE nova.api.openstack Traceback (most recent call last):
2015-07-10 11:20:33.035 TRACE nova.api.openstack File "/opt/stack/
2015-07-10 11:20:33.035 TRACE nova.api.openstack return req.get_
2015-07-10 11:20:33.035 TRACE nova.api.openstack File "/usr/local/
2015-07-10 11:20:33.035 TRACE nova.api.openstack application, catch_exc_
2015-07-10 11:20:33.035 TRACE nova.api.openstack File "/usr/local/
2015-07-10 11:20:33.035 TRACE nova.api.openstack app_iter = application(
2015-07-10 11:20:33.035 TRACE nova.api.openstack File "/usr/local/
2015-07-10 11:20:33.035 TRACE nova.api.openstack return resp(environ, start_response)
2015-07-10 11:20:33.035 TRACE nova.api.openstack File "/usr/local/
2015-07-10 11:20:33.035 TRACE nova.api.openstack resp = self.call_func(req, *args, **self.kwargs)
2015-07-10 11:20:33.035 TRACE nova.api.openstack File "/usr/local/
2015-07-10 11:20:33.035 TRACE nova.api.openstack return self.func(req, *args, **kwargs)
2015-07-10 11:20:33.035 TRACE nova.api.openstack File "/usr/local/
2015-07-10 11:20:33.035 TRACE nova.api.openstack response = req.get_
2015-07-10 11:20:33.035 TRACE nova.api.openstack File "/usr/local/
2015-07-10 11:20:33.035 TRACE nova.api.openstack application, catch_exc_
2015-07-10 11:20:33.035 TRACE nova.api.openstack File "/usr/local/
2015-07-10 11:20:33.035 TRACE nova.api.openstack app_iter = application(
2015-07-10 11:20:33.035 TRACE nova.api.openstack File "/usr/local/
2015-07-10 11:20:33.035 TRACE nova.api.openstack return resp(environ, start_response)
2015-07-10 11:20:33.035 TRACE nova.api.openstack File "/usr/local/
2015-07-10 11:20:33.035 TRACE nova.api.openstack return resp(environ, start_response)
2015-07-...