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

query_async is not working #286

Open
DiarmaidEverycs opened this issue Mar 25, 2020 · 0 comments
Open

query_async is not working #286

DiarmaidEverycs opened this issue Mar 25, 2020 · 0 comments

Comments

@DiarmaidEverycs
Copy link

PyOrient Version: 1.5.5
OrientDB version: 2.2.35

I am trying to asynchronously get records from the database, using the get_query_async() function. I have a very simple example:

`class testGraph():
def add_to_graphl(self, record):
print("We succeeded in getting a record")

def get_from_database(self, client):
""" client --> database connection returned by pyorient.OrientDB(database, port)
query = """select from "
limit = -1
fetchplan = "@*:-2"
client.query_async(query, limit, fetchplan, self.add_to_graph)
`

This is failing with:

pyorient.exceptions.PyOrientBadMethodCallException: <bound method testGraph.add_to_graph of <main.testGraph object at 0x7f5a0e2d3390>> is not a callable function

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