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

Tutorial 4 final steps cause an error #24

Open
yochannah opened this issue Jun 18, 2018 · 2 comments
Open

Tutorial 4 final steps cause an error #24

yochannah opened this issue Jun 18, 2018 · 2 comments

Comments

@yochannah
Copy link
Member

yochannah commented Jun 18, 2018

This might actually be an issue with the python package, but I'll leave that up to you to decide and open in the python client repo if needed.

The issue is in the final couple of lines of tutorial 4 - I thought I'd add a printline statement to see the output for these two lines...

query.add_path_description("ontologyAnnotations.ontologyTerm","Ontology Term")
query.add_path_description("publications","Pub.")

But when I try to print we get a badly formed query error.

You can try it out yourself in this binder instance

Error:

WebserviceError: ('There was a problem with our request', 400, 'Bad Request', u"Query does not pass XML validation. cvc-complex-type.3.2.2: Attribute 'path' is not allowed to appear in element 'pathDescription'.\ncvc-complex-type.4: Attribute 'pathString' must appear on element 'pathDescription'.\ncvc-complex-type.3.2.2: Attribute 'path' is not allowed to appear in element 'pathDescription'.\ncvc-complex-type.4: Attribute 'pathString' must appear on element 'pathDescription'.\n")
@nupurgunwant
Copy link
Member

nupurgunwant commented Jun 19, 2018

True, printing these is unsuccessful.

There seems to be a problem in the function itself, I implied this because the query that given in tutorial 4 using add_path_description, is not a valid one to post on any service(I tried flymine) using its xml which looks like this:
<query longDescription="" model="genomic" name="" sortOrder="Gene.primaryIdentifier asc" view="Gene.primaryIdentifier Gene.symbol Gene.publications.year Gene.publications.firstAuthor Gene.publications.title Gene.ontologyAnnotations.ontologyTerm.name">**<pathDescription description="Ontology Term" path="Gene.ontologyAnnotations.ontologyTerm.name"/>**<constraint code="A" op="=" path="Gene.ontologyAnnotations.ontologyTerm.name" value="*biosynthetic process*"/></query>

However if I remove the bold part, its perfect. So, there is something wrong with the path Description

@yochannah
Copy link
Member Author

@julie-sullivan any idea if pathdescription is supported by mines or not? (e.g. is this a syntax fix or should we we remove it from the tutorial and client?)

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

2 participants