Run() missing 1 required positional argument: 'cypher'

Hello all,

I have a graph that I want to query. I am using py2neo to do the task. However, when I ran the query, It results in the following error even though I installed the stable release."MATCH (a) WHERE$x RETURN, labels(n)", x="Length").evaluate()

Traceback (most recent call last):

File "", line 1, in

TypeError: run() missing 1 required positional argument: 'cypher'

Did the question text box capitalize the G in Graph or is this the way it is written in your code? Graph is the name of the class you import from py2neo. The run method should be called on an instance of Graph, not directly on the class name.
See here for an example:

1 Like

Shouldn't your query be MATCH (n) not MATCH (a) as you use n. in the rest of the query?


That's right. Thank you for your comment!