API failure
tomkukral opened this issue · 1 comments
tomkukral commented
Verify this scenario:
- create resources (namespaced and global)
- delete all resources
- run tests - we expect to get api error
kqueen_1 | [2017-12-04 14:12:21 +0000] [21] [ERROR] Error handling request /api/v1/provisioners
kqueen_1 | Traceback (most recent call last):
kqueen_1 | File "/usr/local/lib/python3.6/site-packages/gunicorn/workers/sync.py", line 135, in handle
kqueen_1 | self.handle_request(listener, req, client, addr)
kqueen_1 | File "/usr/local/lib/python3.6/site-packages/gunicorn/workers/sync.py", line 176, in handle_request
kqueen_1 | respiter = self.wsgi(environ, resp.start_response)
kqueen_1 | File "/usr/local/lib/python3.6/site-packages/flask/app.py", line 1997, in __call__
kqueen_1 | return self.wsgi_app(environ, start_response)
kqueen_1 | File "/usr/local/lib/python3.6/site-packages/flask/app.py", line 1985, in wsgi_app
kqueen_1 | response = self.handle_exception(e)
kqueen_1 | File "/usr/local/lib/python3.6/site-packages/flask/app.py", line 1540, in handle_exception
kqueen_1 | reraise(exc_type, exc_value, tb)
kqueen_1 | File "/usr/local/lib/python3.6/site-packages/flask/_compat.py", line 33, in reraise
kqueen_1 | raise value
kqueen_1 | File "/usr/local/lib/python3.6/site-packages/flask/app.py", line 1982, in wsgi_app
kqueen_1 | response = self.full_dispatch_request()
kqueen_1 | File "/usr/local/lib/python3.6/site-packages/flask/app.py", line 1614, in full_dispatch_request
kqueen_1 | rv = self.handle_user_exception(e)
kqueen_1 | File "/usr/local/lib/python3.6/site-packages/flask/app.py", line 1517, in handle_user_exception
kqueen_1 | reraise(exc_type, exc_value, tb)
kqueen_1 | File "/usr/local/lib/python3.6/site-packages/flask/_compat.py", line 33, in reraise
kqueen_1 | raise value
kqueen_1 | File "/usr/local/lib/python3.6/site-packages/flask/app.py", line 1612, in full_dispatch_request
kqueen_1 | rv = self.dispatch_request()
kqueen_1 | File "/usr/local/lib/python3.6/site-packages/flask/app.py", line 1598, in dispatch_request
kqueen_1 | return self.view_functions[rule.endpoint](**req.view_args)
kqueen_1 | File "/usr/local/lib/python3.6/site-packages/flask/views.py", line 84, in view
kqueen_1 | return self.dispatch_request(*args, **kwargs)
kqueen_1 | File "/usr/local/lib/python3.6/site-packages/kqueen/blueprints/api/generic_views.py", line 25, in dispatch_request
kqueen_1 | output = self.get_content(*args, **kwargs)
kqueen_1 | File "/usr/local/lib/python3.6/site-packages/kqueen/blueprints/api/generic_views.py", line 90, in get_content
kqueen_1 | return list(self.get_class().list(namespace, return_objects=True).values())
kqueen_1 | File "/usr/local/lib/python3.6/site-packages/kqueen/storages/etcd.py", line 365, in list
kqueen_1 | output[result.key.replace(key, '')] = cls.deserialize(result.value, namespace=namespace)
kqueen_1 | File "/usr/local/lib/python3.6/site-packages/kqueen/storages/etcd.py", line 401, in deserialize
kqueen_1 | toplevel = json.loads(serialized)
kqueen_1 | File "/usr/local/lib/python3.6/json/__init__.py", line 348, in loads
kqueen_1 | 'not {!r}'.format(s.__class__.__name__))
kqueen_1 | TypeError: the JSON object must be str, bytes or bytearray, not 'NoneType'
``