In pyTigerGraph module, pyDriver.py we are setting self.ExceptionDetected = True if line starts with “GSQL__RETURN__CODE”. We gave some print statements and found even for a statement like “drop query all” the ret value is 212 but the message is successful one “All queries are dropped”. Can you please explain why statuscode is not 0 and if it is 212 why it doesn’t throw any error.
We executed by giving a simple query like “ls” and statuscode(ret value) is 0 which is fine, if we give query like “lss” statuscode(ret value) is 211 which is also fine. But not sure why ret value is 212 for query “drop query all”
The code I am referring
def _command_interactive(self, url, content, ans="", out=False):
res = 
for line in reader:
line = line.strip()
_, ret = line.split(",", 1)
ret = int(ret)
if ret != 0:
self.ExceptionDetected = True
# raise ExceptionCodeRet(ret)
Also error codes mentioned in the link is referring ret value given in the above code snippet?
@karnamthulasiram , from the error code you have I assume that you’re using an old version of pyTigerGraph :
could you use
pip install -U pyTigerDriver pyTigerGraph
@Mohamed_Zrouga We are using tigergraph3.2 database using docker containers. I feel the issue is not with pyTigergraph or pyTigerDriver modules. After running the tigergraph image(database) as containers it exposes url “http://localhost:14240/gsqlserver/gsql/file” where all gsql queries are passed. The response of the endpoint(ultimately tigergraph docker image) sends non 0 status code, sometimes, for correct queries.
PyTigerDriver and pyTigerGraph are just calling the mentioned endpoint, by passing gsql queries and does some processing on top of it. Please let me know if I am missing anything
@karnamthulasiram, thanks for the reply, the upgrade hint was because the latest pyTigerGraph displays the errors and not the codes, and since you’re getting the old format 211 or 212 I’m assuming you’re running an old pyTigerGraph and pyTigerDriver version.
pip show pyTigerGraph // latest should be 0.0.9.8.5
pip show pyTigerDriver // latest should be 1.0.14
for the commands passed and their output, once you have upgraded to the latest pyTG you should be able to see plain text errors from the engine ( that will explain what’s happening )
feel free to ping me for a zoom session if you need to deep dive into it.