← Back to team overview

yahoo-eng-team team mailing list archive

[Bug 1681843] [NEW] Nova-placement returns "ValueError: invalid literal for int() with base 10: ''"

 

Public bug reported:

Since
https://github.com/openstack/nova/commit/6dd047a3307a1056077608fd5bc2d1c3b3285338
we're seeing errors for Nova-placement service in the OpenStack-Ansible
gate jobs:

2017-04-10 17:43:45.761 2477 ERROR nova.api.openstack [req-a9cb7079-b603-4c2c-9f99-8bc4293f9700 78e46f12329c4f71a7f6b97aa3a7eb57 f7d6ca89f4fb446eaebef93f7f235a50 - default default] Caught error: invalid literal for int() with base 10: ''
2017-04-10 17:43:45.761 2477 ERROR nova.api.openstack Traceback (most recent call last):
2017-04-10 17:43:45.761 2477 ERROR nova.api.openstack   File "/openstack/venvs/nova-master/lib/python2.7/site-packages/nova/api/openstack/__init__.py", line 85, in __call__
2017-04-10 17:43:45.761 2477 ERROR nova.api.openstack     return req.get_response(self.application)
2017-04-10 17:43:45.761 2477 ERROR nova.api.openstack   File "/openstack/venvs/nova-master/lib/python2.7/site-packages/webob/request.py", line 1316, in send
2017-04-10 17:43:45.761 2477 ERROR nova.api.openstack     application, catch_exc_info=False)
2017-04-10 17:43:45.761 2477 ERROR nova.api.openstack   File "/openstack/venvs/nova-master/lib/python2.7/site-packages/webob/request.py", line 1280, in call_application
2017-04-10 17:43:45.761 2477 ERROR nova.api.openstack     app_iter = application(self.environ, start_response)
2017-04-10 17:43:45.761 2477 ERROR nova.api.openstack   File "/openstack/venvs/nova-master/lib/python2.7/site-packages/webob/dec.py", line 131, in __call__
2017-04-10 17:43:45.761 2477 ERROR nova.api.openstack     resp = self.call_func(req, *args, **self.kwargs)
2017-04-10 17:43:45.761 2477 ERROR nova.api.openstack   File "/openstack/venvs/nova-master/lib/python2.7/site-packages/webob/dec.py", line 196, in call_func
2017-04-10 17:43:45.761 2477 ERROR nova.api.openstack     return self.func(req, *args, **kwargs)
2017-04-10 17:43:45.761 2477 ERROR nova.api.openstack   File "/openstack/venvs/nova-master/lib/python2.7/site-packages/nova/api/openstack/placement/microversion.py", line 123, in __call__
2017-04-10 17:43:45.761 2477 ERROR nova.api.openstack     response = req.get_response(self.application)
2017-04-10 17:43:45.761 2477 ERROR nova.api.openstack   File "/openstack/venvs/nova-master/lib/python2.7/site-packages/webob/request.py", line 1316, in send
2017-04-10 17:43:45.761 2477 ERROR nova.api.openstack     application, catch_exc_info=False)
2017-04-10 17:43:45.761 2477 ERROR nova.api.openstack   File "/openstack/venvs/nova-master/lib/python2.7/site-packages/webob/request.py", line 1280, in call_application
2017-04-10 17:43:45.761 2477 ERROR nova.api.openstack     app_iter = application(self.environ, start_response)
2017-04-10 17:43:45.761 2477 ERROR nova.api.openstack   File "/openstack/venvs/nova-master/lib/python2.7/site-packages/nova/api/openstack/placement/handler.py", line 182, in __call__
2017-04-10 17:43:45.761 2477 ERROR nova.api.openstack     if int(environ.get('CONTENT_LENGTH', 0)):
2017-04-10 17:43:45.761 2477 ERROR nova.api.openstack ValueError: invalid literal for int() with base 10: ''
2017-04-10 17:43:45.761 2477 ERROR nova.api.openstack 

================================

The Error is occurring because "CONTENT_LENGTH" is present but = '' and
the change attempts to set "None" to an int - which fails.

We're using Nginx /w uWSGI and I believe a default uwsgi param is set to
always send a CONTENT_LENGTH and CONTENT_TYPE header even when those are
empty.

** Affects: nova
     Importance: Undecided
         Status: New

-- 
You received this bug notification because you are a member of Yahoo!
Engineering Team, which is subscribed to OpenStack Compute (nova).
https://bugs.launchpad.net/bugs/1681843

Title:
  Nova-placement returns "ValueError: invalid literal for int() with
  base 10: ''"

Status in OpenStack Compute (nova):
  New

Bug description:
  Since
  https://github.com/openstack/nova/commit/6dd047a3307a1056077608fd5bc2d1c3b3285338
  we're seeing errors for Nova-placement service in the OpenStack-
  Ansible gate jobs:

  2017-04-10 17:43:45.761 2477 ERROR nova.api.openstack [req-a9cb7079-b603-4c2c-9f99-8bc4293f9700 78e46f12329c4f71a7f6b97aa3a7eb57 f7d6ca89f4fb446eaebef93f7f235a50 - default default] Caught error: invalid literal for int() with base 10: ''
  2017-04-10 17:43:45.761 2477 ERROR nova.api.openstack Traceback (most recent call last):
  2017-04-10 17:43:45.761 2477 ERROR nova.api.openstack   File "/openstack/venvs/nova-master/lib/python2.7/site-packages/nova/api/openstack/__init__.py", line 85, in __call__
  2017-04-10 17:43:45.761 2477 ERROR nova.api.openstack     return req.get_response(self.application)
  2017-04-10 17:43:45.761 2477 ERROR nova.api.openstack   File "/openstack/venvs/nova-master/lib/python2.7/site-packages/webob/request.py", line 1316, in send
  2017-04-10 17:43:45.761 2477 ERROR nova.api.openstack     application, catch_exc_info=False)
  2017-04-10 17:43:45.761 2477 ERROR nova.api.openstack   File "/openstack/venvs/nova-master/lib/python2.7/site-packages/webob/request.py", line 1280, in call_application
  2017-04-10 17:43:45.761 2477 ERROR nova.api.openstack     app_iter = application(self.environ, start_response)
  2017-04-10 17:43:45.761 2477 ERROR nova.api.openstack   File "/openstack/venvs/nova-master/lib/python2.7/site-packages/webob/dec.py", line 131, in __call__
  2017-04-10 17:43:45.761 2477 ERROR nova.api.openstack     resp = self.call_func(req, *args, **self.kwargs)
  2017-04-10 17:43:45.761 2477 ERROR nova.api.openstack   File "/openstack/venvs/nova-master/lib/python2.7/site-packages/webob/dec.py", line 196, in call_func
  2017-04-10 17:43:45.761 2477 ERROR nova.api.openstack     return self.func(req, *args, **kwargs)
  2017-04-10 17:43:45.761 2477 ERROR nova.api.openstack   File "/openstack/venvs/nova-master/lib/python2.7/site-packages/nova/api/openstack/placement/microversion.py", line 123, in __call__
  2017-04-10 17:43:45.761 2477 ERROR nova.api.openstack     response = req.get_response(self.application)
  2017-04-10 17:43:45.761 2477 ERROR nova.api.openstack   File "/openstack/venvs/nova-master/lib/python2.7/site-packages/webob/request.py", line 1316, in send
  2017-04-10 17:43:45.761 2477 ERROR nova.api.openstack     application, catch_exc_info=False)
  2017-04-10 17:43:45.761 2477 ERROR nova.api.openstack   File "/openstack/venvs/nova-master/lib/python2.7/site-packages/webob/request.py", line 1280, in call_application
  2017-04-10 17:43:45.761 2477 ERROR nova.api.openstack     app_iter = application(self.environ, start_response)
  2017-04-10 17:43:45.761 2477 ERROR nova.api.openstack   File "/openstack/venvs/nova-master/lib/python2.7/site-packages/nova/api/openstack/placement/handler.py", line 182, in __call__
  2017-04-10 17:43:45.761 2477 ERROR nova.api.openstack     if int(environ.get('CONTENT_LENGTH', 0)):
  2017-04-10 17:43:45.761 2477 ERROR nova.api.openstack ValueError: invalid literal for int() with base 10: ''
  2017-04-10 17:43:45.761 2477 ERROR nova.api.openstack 

  ================================

  The Error is occurring because "CONTENT_LENGTH" is present but = ''
  and the change attempts to set "None" to an int - which fails.

  We're using Nginx /w uWSGI and I believe a default uwsgi param is set
  to always send a CONTENT_LENGTH and CONTENT_TYPE header even when
  those are empty.

To manage notifications about this bug go to:
https://bugs.launchpad.net/nova/+bug/1681843/+subscriptions


Follow ups