Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Validation fails for failed actions (and possibly tracebacks) with additional extracted fields #242

Closed
itamarst opened this issue Dec 1, 2015 · 0 comments

Comments

@itamarst
Copy link
Owner

itamarst commented Dec 1, 2015

Given an exception extractor, validation of logging in a test started failing:

Traceback (most recent call last):
  File "/home/itamarst/ClusterHQ/flocker/.tox/py27/local/lib/python2.7/site-packages/twisted/trial/_synctest.py", line 1368, in _runCleanups
    f(*args, **kwargs)
  File "/home/itamarst/ClusterHQ/flocker/.tox/py27/local/lib/python2.7/site-packages/eliot/_output.py", line 295, in validate
    serializer.validate(dictionary)
  File "/home/itamarst/ClusterHQ/flocker/.tox/py27/local/lib/python2.7/site-packages/eliot/_validation.py", line 266, in validate
    raise ValidationError(message, "Unexpected field %r" % (key,))
eliot._validation.ValidationError: ({u'action_status': u'failed', u'task_level': [3, 2], u'timestamp': 1449003265.709564, u'task_uuid': u'f6a314ab-2e97-42e6-821c-e30ff2023195', u'action_type': u'api:json_request', u'code': 402, u'exception': u'flocker.restapi._error.BadRequest', u'reason': u"(402, u'additional details here')"}, u"Unexpected field u'code'")
itamarst added a commit that referenced this issue Dec 1, 2015
Fix validation of extracted exception fields.

Fixes #242.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant