code: def _parse_action(action):
      
      i_open = action.find('(')
      if i_open is -1:
          # return action name, finished
          return {'name': action, 'args': [], 'event_args': False}
      # we need to parse the arguments
      i_close = action.rfind(')')
      if i_close is -1:
          raise Exception('Bracket in argument opened but not closed.')
      action_name = action[:i_open]
      arglist = action[i_open+1:i_close].strip()
      if not arglist:
          # no arglist, just return method name
          return {'name': action_name, 'args': [], 'event_args': False}
      if '*' in arglist:
          return {'name': action_name, 'args': [], 'event_args': True}
      return {'name': action_name, 'args': _parse_arg_list(arglist), 'event_args': False}
docs: Parses a single action item, for instance one of the following:
  
          m; m(); m(True); m(*)
  
      The brackets must match.