yahoo-eng-team team mailing list archive
-
yahoo-eng-team team
-
Mailing list archive
-
Message #12071
[Bug 1296589] [NEW] Image API v2 image tags broken with E500
Public bug reported:
There is set([]) passed to json.dumps() which is not parseable:
self.func(req, *args, **kwargs)
File "/usr/lib/python2.7/dist-packages/glance/common/wsgi.py", line 625, in __call__
request, **action_args)
File "/usr/lib/python2.7/dist-packages/glance/common/wsgi.py", line 644, in dispatch
return method(*args, **kwargs)
File "/usr/lib/python2.7/dist-packages/glance/common/utils.py", line 422, in wrapped
return func(self, req, *args, **kwargs)
File "/usr/lib/python2.7/dist-packages/glance/api/v2/image_tags.py",
line 46, in update
image_repo.save(image)
File "/usr/lib/python2.7/dist-packages/glance/domain/proxy.py", line 65, in save
result = self.base.save(base_item)
File "/usr/lib/python2.7/dist-packages/glance/domain/proxy.py", line 65, in save
result = self.base.save(base_item)
File "/usr/lib/python2.7/dist-packages/glance/notifier/__init__.py", line 140, in save
super(ImageRepoProxy, self).save(image)
File
"/usr/lib/python2.7/dist-packages/glance/domain/proxy.py", line 65, in save
result = self.base.save(base_item)
File "/usr/lib/python2.7/dist-packages/glance/api/policy.py", line 186, in save
return super(ImageRepoProxy, self).save(image)
File "/usr/lib/python2.7/dist-packages/glance/domain/proxy.py", line 65, in save
result = self.base.save(base_item)
File "/usr/lib/python2.7/dist-packages/glance/domain/proxy.py", line 65, in save
result = self.base.save(base_item)
File "/usr/lib/python2.7/dist-packages/glance/store/__init__.py", line 398, in save
result = super(ImageRepoProxy, self).save(image)
File "/usr/lib/python2.7/dist-packages/glance/domain/proxy.py", line 65, in save
result = self.base.save(base_item)
File "/usr/lib/python2.7/dist-packages/glance/db/__init__.py", line 170, in save
image.tags)
File "/usr/lib/python2.7/dist-packages/glance/db/registry/api.py", line 59,
in wrapper
return func(client, *args, **kwargs)
File "/usr/lib/python2.7/dist-packages/glance/db/registry/api.py", line 200, in image_tag_set_all
client.image_tag_set_all(image_id=image_id, tags=tags)
File "/usr/lib/python2.7/dist-packages/glance/common/rpc.py", line 274, in method_proxy
return self.do_request(item, **kw)
File "/usr/lib/python2.7/dist-packages/glance/common/rpc.py", line 240, in do_request
'kwargs': kwargs}])
File
"/usr/lib/python2.7/dist-packages/glance/common/client.py", line 64, in wrapped
return func(self, *args, **kwargs)
File "/usr/lib/python2.7/dist-packages/glance/common/rpc.py", line 223, in bulk_request
body = self._serializer.to_json(commands)
File "/usr/lib/python2.7/dist-packages/glance/common/wsgi.py", line 577, in to_json
return json.dumps(data, default=self._sanitizer)
File "/usr/lib/python2.7/json/__init__.py", line 238, in dumps
**kw).encode(obj)
File "/usr/lib/python2.7/json/encoder.py", line 201, in encode
chunks = self.iterencode(o, _one_shot=True)
File "/usr/lib/python2.7/json/encoder.py", line 264, in iterencode
return _iterencode(o, 0)
ValueError: Circular reference detected
After adding sanitizer check for it the sqlalchemy gets empty id to fetch:
Mar 21 14:58:26.627 HOST 24293 DEBUG glance.db.sqlalchemy.api [...] No image found with ID None
Mar 21 14:58:26.628 HOST 24293 ERROR glance.common.rpc [...] RPC Call Error: No image found with ID None
Traceback (most recent call last):
File "/usr/lib/python2.7/dist-packages/glance/common/rpc.py", line 177, in __call__
result = method(req.context, **kwargs)
File "/usr/lib/python2.7/dist-packages/glance/db/sqlalchemy/api.py", line 832, in image_get_all
force_show_deleted=showing_deleted)
File "/usr/lib/python2.7/dist-packages/glance/db/sqlalchemy/api.py", line 451, in _image_get
raise exception.NotFound(msg)
NotFound: No image found with ID None
** Affects: glance
Importance: Undecided
Assignee: Erno Kuvaja (jokke)
Status: New
** Changed in: glance
Assignee: (unassigned) => Erno Kuvaja (jokke)
--
You received this bug notification because you are a member of Yahoo!
Engineering Team, which is subscribed to Glance.
https://bugs.launchpad.net/bugs/1296589
Title:
Image API v2 image tags broken with E500
Status in OpenStack Image Registry and Delivery Service (Glance):
New
Bug description:
There is set([]) passed to json.dumps() which is not parseable:
self.func(req, *args, **kwargs)
File "/usr/lib/python2.7/dist-packages/glance/common/wsgi.py", line 625, in __call__
request, **action_args)
File "/usr/lib/python2.7/dist-packages/glance/common/wsgi.py", line 644, in dispatch
return method(*args, **kwargs)
File "/usr/lib/python2.7/dist-packages/glance/common/utils.py", line 422, in wrapped
return func(self, req, *args, **kwargs)
File "/usr/lib/python2.7/dist-packages/glance/api/v2/image_tags.py",
line 46, in update
image_repo.save(image)
File "/usr/lib/python2.7/dist-packages/glance/domain/proxy.py", line 65, in save
result = self.base.save(base_item)
File "/usr/lib/python2.7/dist-packages/glance/domain/proxy.py", line 65, in save
result = self.base.save(base_item)
File "/usr/lib/python2.7/dist-packages/glance/notifier/__init__.py", line 140, in save
super(ImageRepoProxy, self).save(image)
File
"/usr/lib/python2.7/dist-packages/glance/domain/proxy.py", line 65, in save
result = self.base.save(base_item)
File "/usr/lib/python2.7/dist-packages/glance/api/policy.py", line 186, in save
return super(ImageRepoProxy, self).save(image)
File "/usr/lib/python2.7/dist-packages/glance/domain/proxy.py", line 65, in save
result = self.base.save(base_item)
File "/usr/lib/python2.7/dist-packages/glance/domain/proxy.py", line 65, in save
result = self.base.save(base_item)
File "/usr/lib/python2.7/dist-packages/glance/store/__init__.py", line 398, in save
result = super(ImageRepoProxy, self).save(image)
File "/usr/lib/python2.7/dist-packages/glance/domain/proxy.py", line 65, in save
result = self.base.save(base_item)
File "/usr/lib/python2.7/dist-packages/glance/db/__init__.py", line 170, in save
image.tags)
File "/usr/lib/python2.7/dist-packages/glance/db/registry/api.py", line 59,
in wrapper
return func(client, *args, **kwargs)
File "/usr/lib/python2.7/dist-packages/glance/db/registry/api.py", line 200, in image_tag_set_all
client.image_tag_set_all(image_id=image_id, tags=tags)
File "/usr/lib/python2.7/dist-packages/glance/common/rpc.py", line 274, in method_proxy
return self.do_request(item, **kw)
File "/usr/lib/python2.7/dist-packages/glance/common/rpc.py", line 240, in do_request
'kwargs': kwargs}])
File
"/usr/lib/python2.7/dist-packages/glance/common/client.py", line 64, in wrapped
return func(self, *args, **kwargs)
File "/usr/lib/python2.7/dist-packages/glance/common/rpc.py", line 223, in bulk_request
body = self._serializer.to_json(commands)
File "/usr/lib/python2.7/dist-packages/glance/common/wsgi.py", line 577, in to_json
return json.dumps(data, default=self._sanitizer)
File "/usr/lib/python2.7/json/__init__.py", line 238, in dumps
**kw).encode(obj)
File "/usr/lib/python2.7/json/encoder.py", line 201, in encode
chunks = self.iterencode(o, _one_shot=True)
File "/usr/lib/python2.7/json/encoder.py", line 264, in iterencode
return _iterencode(o, 0)
ValueError: Circular reference detected
After adding sanitizer check for it the sqlalchemy gets empty id to fetch:
Mar 21 14:58:26.627 HOST 24293 DEBUG glance.db.sqlalchemy.api [...] No image found with ID None
Mar 21 14:58:26.628 HOST 24293 ERROR glance.common.rpc [...] RPC Call Error: No image found with ID None
Traceback (most recent call last):
File "/usr/lib/python2.7/dist-packages/glance/common/rpc.py", line 177, in __call__
result = method(req.context, **kwargs)
File "/usr/lib/python2.7/dist-packages/glance/db/sqlalchemy/api.py", line 832, in image_get_all
force_show_deleted=showing_deleted)
File "/usr/lib/python2.7/dist-packages/glance/db/sqlalchemy/api.py", line 451, in _image_get
raise exception.NotFound(msg)
NotFound: No image found with ID None
To manage notifications about this bug go to:
https://bugs.launchpad.net/glance/+bug/1296589/+subscriptions
Follow ups
References