Пример #1
0
 def message_to_kitty(self, global_opts: RCOptions, opts: 'CLIOptions',
                      args: ArgsType) -> PayloadType:
     if len(args) < 2:
         self.fatal('Invalid marker specification: {}'.format(
             ' '.join(args)))
     parse_marker_spec(args[0], args[1:])
     return {'match': opts.match, 'self': opts.self, 'marker_spec': args}
Пример #2
0
 def message_to_kitty(self, global_opts: RCOptions, opts: 'CLIOptions', args: ArgsType) -> PayloadType:
     if len(args) < 2:
         self.fatal('Invalid marker specification: {}'.format(' '.join(args)))
     try:
         parse_marker_spec(args[0], args[1:])
     except Exception as err:
         self.fatal(f"Failed to parse marker specification {' '.join(args)} with error: {err}")
     return {'match': opts.match, 'self': opts.self, 'marker_spec': args}