The message refers to the line
if self.find_action(self, bit) is not None:
If I run I get the error: TypeError: find_action() takes 2 positional arguments but 3 were given
def find_action(self, search_term):
for action in self.actions:
bits = re.split(";", action)
for bit in bits:
if bit == search_term:
return action
return None
def check_action_free(self, params):
bits = re.split(";", params)
for bit in bits:
if self.find_action(self, bit) is not None:
return False
return True