← Back to team overview

yahoo-eng-team team mailing list archive

[Bug 1183860] Re: Registry 500 error when listing images whose names are null

 

** Changed in: glance
       Status: Fix Committed => Fix Released

** Changed in: glance
    Milestone: None => havana-2

-- 
You received this bug notification because you are a member of Yahoo!
Engineering Team, which is subscribed to Glance.
https://bugs.launchpad.net/bugs/1183860

Title:
  Registry 500 error when listing images whose names are null

Status in OpenStack Image Registry and Delivery Service (Glance):
  Fix Released

Bug description:
  create some images with nothing in the name field:

   $ glance --os-password XXX  --os-username glance --os-tenant-name service  --os-auth-url http://localhost:5000/v2.0 index
  ID                                   Name                           Disk Format          Container Format     Size          
  ------------------------------------ ------------------------------ -------------------- -------------------- --------------
  3b3d1744-a378-4e46-a766-23b8e90f3270 None                           raw                  bare                            754
  6588874b-d96d-440b-a419-e155d5dd21f9 None                           raw                  bare                            754
  7d12f2ba-a1f5-4dc7-852a-2b5006eac7fb None                           raw                  bare                            754
  ea893248-87d7-49d8-ab5f-8c46077377cc None                           raw                  bare                            754
  3ee241b5-4f85-4bb0-9349-efd4af310dbb x2                             raw                  bare                            754
  c7863541-a755-4063-a982-bc8a73dfed43 x2                             raw                  bare                            754
  2a62cba7-5a70-4727-95d2-c0f89bd025ef x2                             raw                  bare                            754
  3a71302d-0870-4154-80d4-703e940922b4 x1                             raw                  bare                            754
  e921ee68-31a8-41b8-9232-733d22c7e113 cirros-0.3.1-x86_64-uec        ami                  ami                        25165824
  a2558cbc-f8ba-45e0-be79-747f04cbd0ed cirros-0.3.1-x86_64-uec-kernel aki                  aki                         4955792
  5e2e2e49-fe1d-4568-9996-5d86e5322845 cirros-0.3.1-x86_64-uec-ramdis ari                  ari                         3714968

  
  Now, using a small page size, perform an image list:

  $ glance --os-password hpinvent  --os-username glance --os-tenant-name service  --os-auth-url http://localhost:5000/v2.0 image-list --page-size 3
  Request returned failure status.
  Traceback (most recent call last):
    File "/usr/local/lib/python2.7/dist-packages/eventlet/wsgi.py", line 383, in handle_one_response
      result = self.application(self.environ, start_response)
    File "/usr/local/lib/python2.7/dist-packages/webob/dec.py", line 130, in __call__
      resp = self.call_func(req, *args, **self.kwargs)
    File "/usr/local/lib/python2.7/dist-packages/webob/dec.py", line 195, in call_func
      return self.func(req, *args, **kwargs)
    File "/opt/stack/glance/glance/common/wsgi.py", line 367, in __call__
      response = req.get_response(self.application)
    File "/usr/local/lib/python2.7/dist-packages/webob/request.py", line 1296, in send
      application, catch_exc_info=False)
    File "/usr/local/lib/python2.7/dist-packages/webob/request.py", line 1260, in call_application
      app_iter = application(self.environ, start_response)
    File "/opt/stack/python-keystoneclient/keystoneclient/middleware/auth_token.py", line 456, in __call__
      return self.app(env, start_response)
    File "/usr/local/lib/python2.7/dist-packages/webob/dec.py", line 130, in __call__
      resp = self.call_func(req, *args, **self.kwargs)
    File "/usr/local/lib/python2.7/dist-packages/webob/dec.py", line 195, in call_func
      return self.func(req, *args, **kwargs)
    File "/opt/stack/glance/glance/common/wsgi.py", line 367, in __call__
      response = req.get_response(self.application)
    File "/usr/local/lib/python2.7/dist-packages/webob/request.py", line 1296, in send
      application, catch_exc_info=False)
    File "/usr/local/lib/python2.7/dist-packages/webob/request.py", line 1260, in call_application
      app_iter = application(self.environ, start_response)
    File "/usr/local/lib/python2.7/dist-packages/webob/dec.py", line 130, in __call__
      resp = self.call_func(req, *args, **self.kwargs)
    File "/usr/local/lib/python2.7/dist-packages/webob/dec.py", line 195, in call_func
      return self.func(req, *args, **kwargs)
    File "/opt/stack/glance/glance/common/wsgi.py", line 367, in __call__
      response = req.get_response(self.application)
    File "/usr/local/lib/python2.7/dist-packages/webob/request.py", line 1296, in send
      application, catch_exc_info=False)
    File "/usr/local/lib/python2.7/dist-packages/webob/request.py", line 1260, in call_application
      app_iter = application(self.environ, start_response)
    File "/usr/local/lib/python2.7/dist-packages/webob/dec.py", line 130, in __call__
      resp = self.call_func(req, *args, **self.kwargs)
    File "/usr/local/lib/python2.7/dist-packages/webob/dec.py", line 195, in call_func
      return self.func(req, *args, **kwargs)
    File "/opt/stack/glance/glance/common/wsgi.py", line 367, in __call__
      response = req.get_response(self.application)
    File "/usr/local/lib/python2.7/dist-packages/webob/request.py", line 1296, in send
      application, catch_exc_info=False)
    File "/usr/local/lib/python2.7/dist-packages/webob/request.py", line 1260, in call_application
      app_iter = application(self.environ, start_response)
    File "/usr/lib/python2.7/dist-packages/paste/urlmap.py", line 203, in __call__
      return app(environ, start_response)
    File "/usr/local/lib/python2.7/dist-packages/webob/dec.py", line 144, in __call__
      return resp(environ, start_response)
    File "/usr/lib/python2.7/dist-packages/routes/middleware.py", line 131, in __call__
      response = self.app(environ, start_response)
    File "/usr/local/lib/python2.7/dist-packages/webob/dec.py", line 144, in __call__
      return resp(environ, start_response)
    File "/usr/local/lib/python2.7/dist-packages/webob/dec.py", line 130, in __call__
      resp = self.call_func(req, *args, **self.kwargs)
    File "/usr/local/lib/python2.7/dist-packages/webob/dec.py", line 195, in call_func
      return self.func(req, *args, **kwargs)
    File "/opt/stack/glance/glance/common/wsgi.py", line 591, in __call__
      request, **action_args)
    File "/opt/stack/glance/glance/common/wsgi.py", line 608, in dispatch
      return method(*args, **kwargs)
    File "/opt/stack/glance/glance/api/v1/images.py", line 204, in detail
      images = registry.get_images_detail(req.context, **params)
    File "/opt/stack/glance/glance/registry/client/v1/api.py", line 148, in get_images_detail
      return c.get_images_detailed(**kwargs)
    File "/opt/stack/glance/glance/registry/client/v1/client.py", line 115, in get_images_detailed
      res = self.do_request("GET", "/images/detail", params=params)
    File "/opt/stack/glance/glance/registry/client/v1/client.py", line 90, in do_request
      **kwargs)
    File "/opt/stack/glance/glance/common/client.py", line 62, in wrapped
      return func(self, *args, **kwargs)
    File "/opt/stack/glance/glance/common/client.py", line 376, in do_request
      headers=headers)
    File "/opt/stack/glance/glance/common/client.py", line 79, in wrapped
      return func(self, method, url, body, headers)
    File "/opt/stack/glance/glance/common/client.py", line 514, in _do_request
      raise exception.ServerError()

  
  The registry stack trace ends with:

   exc.ArgumentError("Only '='/'Unable to render embedded object: File (
  Only '='/') not found.=' operators can be used with NULL

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