nova 커맨드를 실행하다가 아래와 같은 에러를 만났다.


$ nova quota-show --user $projectUser --tenant $project

ERROR (AttributeError): 'unicode' object has no attribute 'get'




다음 코드를 써서 해결할 수 있는 경우가 있다.


export PYTHONIOENCODING=UTF-8



그래도 에러가 발생하면. 이전 컴맨드에 --debug를 추가하면.. 확실히 알 수 있다.


 404 not found.. API 이슈이다. 


$ nova quota-show --user $projecUser --tenant $project --debug

DEBUG (session:198) REQ: curl -g -i -X GET https://code.google.io:5000/v2.0/ -H "Accept: application/json" -H "User-Agent: python-keystoneclient"

...

DEBUG (connectionpool:387) "GET /v2/ae17dbd7165142808e074579360a8b9c HTTP/1.1" 404 112

DEBUG (session:215) RESP: [404] Date: Tue, 12 Jun 2018 08:01:07 GMT Content-Length: 112 Content-Type: application/json; charset=UTF-8 X-Compute-Request-Id: req-0a8e18ed-860e-4dcb-a566-f7eb02fb19bd

RESP BODY: {"message": "The resource could not be found.<br /><br />\n\n\n", "code": "404 Not Found", "title": "Not Found"}


DEBUG (shell:909) 'unicode' object has no attribute 'get'







Posted by '김용환'
,