Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
def getEvents(scABI):
events = []
for i in scABI:
if i["type"] == "event":
args = []
for j in i["inputs"]:
args.append(j["type"])
esig = i["name"] + "(" + ','.join(args) + ")"
event = {
"hash": '0x' + utils.sha3(esig).encode("hex"),
"argsig": args,
"name": esig
}
events.append(event)
return events