MCPcopy Create free account
hub / github.com/HexHive/NASS / get_arg

Function get_arg

data/interface_db.py:108–123  ·  view source on GitHub ↗
(connection, interface_id, ordering)

Source from the content-addressed store, hash-verified

106 print(f'[BINDERDB] Failed insert/update of service {str(e)}, {traceback.format_exc()}')
107
108def get_arg(connection, interface_id, ordering):
109 try:
110 cursor = connection.cursor()
111 select_data_query = "SELECT * from args WHERE interface_id = ? AND ordering = ?"
112 cursor.execute(select_data_query, (interface_id, ordering, ))
113 rows = cursor.fetchall()
114 if len(rows) == 0:
115 return None
116 r = rows[0]
117 a_id = r[0]
118 ordering = r[1]
119 argtype = r[2]
120 return Arg(argtype, db_id=a_id)
121 except Exception as e:
122 logging.error(f'[BINDERDB] Failed retrieving interface {str(e)}, {traceback.format_exc()}')
123 print(f'[BINDERDB] Failed retrieving interface {str(e)}, {traceback.format_exc()}')
124
125def get_args(connection, interface_id):
126 try:

Callers 1

insert_update_argFunction · 0.85

Calls 1

ArgClass · 0.90

Tested by

no test coverage detected