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

fix get_case_observables method #53

Merged
merged 2 commits into from
Dec 19, 2017

Conversation

billmurrin
Copy link

With the most recent version of TheHive4Py, trying to retrieve observables programmatically via the get_case_observables method was throwing the following error:

{u'message': u'JsResultException(errors:List((,List(JsonValidationError(List(Invalid query: unexpected [{"_parent":{"_type":"case","_query":{"_id":"AWA9SlYM_XlqkMKDzIB0"}}},{"_value":"Ok","_field":"status"}]),WrappedArray())))))', u'type': u'play.api.libs.json.JsResultException'}

I updated the code using the same structure present in the get_case_tasks method.

@billmurrin billmurrin changed the title fix get_case_observable method fix get_case_observables method Dec 19, 2017
@billmurrin billmurrin changed the base branch from master to develop December 19, 2017 06:35
@nadouani
Copy link
Contributor

Thanks, in fact the And methods uses args not an array as params.

@nadouani nadouani merged commit 5c22104 into TheHive-Project:develop Dec 19, 2017
@nadouani nadouani added this to the 1.4.1 milestone Dec 19, 2017
@billmurrin billmurrin deleted the pr-fix-observable-query branch December 19, 2017 23:03
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

Successfully merging this pull request may close these issues.

2 participants