

def __call__(self):
    'Calls the wrapped function through the lens of a CLI ran command'
    for requirement in self.requires:
        conclusion = requirement(request=sys.argv, module=self.api.module)
        if (conclusion and (conclusion is not True)):
            return self.output(conclusion)
    pass_to_function = vars(self.parser.parse_known_args()[0])
    for (option, directive) in self.directives.items():
        arguments = ((self.defaults[option],) if (option in self.defaults) else ())
        pass_to_function[option] = directive(*arguments, api=self.api, argparse=karg_values.parser, interface=self)
    if getattr(self, 'validate_function', False):
        errors = self.validate_function(pass_to_function)
        if errors:
            return self.output(errors)
    if hasattr(self.interface, 'karg'):
        karg_values = pass_to_function.pop(self.interface.karg, ())
        result = self.interface(*karg_values, **pass_to_function)
    else:
        result = self.interface(**pass_to_function)
    return self.output(result)

dataset/ETHPy150Open timothycrosley/hug/hug/interface.py CLI.__call__/VarMisuse@140/190 `self`->`karg_values`