How i can call first.TQ in Second ? Without creating object First in Second.
class First:
def __init__(self):
self.str = ""
def TQ(self):
pass
def main(self):
T = Second(self.str) # Called here
class Second():
def __init__(self):
list = {u"RANDINT":first.TQ} # List of funcs maybe called in first
.....
.....
return data
TQinSecondsinceSeconddoesn't haveTQmethod. You probably wantclass Second(First):. Also, you shouldn't return a value for__init__.