Skip to content

Commit

Permalink
Fix json_with_params (#203)
Browse files Browse the repository at this point in the history
  • Loading branch information
wey-gu committed Mar 3, 2022
1 parent cec1f47 commit 4c4f2be
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions nebula3/gclient/net/Connection.py
Original file line number Diff line number Diff line change
Expand Up @@ -163,13 +163,14 @@ def execute_json(self, session_id, stmt):
return self.execute_json_with_parameter(session_id, stmt, None)

def execute_json_with_parameter(self, session_id, stmt, params):
"""execute_json interface with session_id and ngql
"""execute_json interface with session_id and ngql with parameter
:param session_id: the session id get from result of authenticate interface
:param stmt: the ngql
:param params: parameter map
:return: string json representing the execution result
"""
try:
resp = self._connection.executeJsonWithParameter(session_id, stmt)
resp = self._connection.executeJsonWithParameter(session_id, stmt, params)
return resp
except Exception as te:
if isinstance(te, TTransportException):
Expand Down

0 comments on commit 4c4f2be

Please sign in to comment.