Ejemplo n.º 1
0
    def _resolve_hook(self, name, callable_or_name, ignore_failure):
        if is_callable(callable_or_name):
            self.hooks[name] = callable_or_name
        else:
            # will raise ImportError on failure
            self.hooks[name] = resolve_name(callable_or_name)

        if ignore_failure:
            self.ignore_hook_failure.append(name)
Ejemplo n.º 2
0
    def _resolve_hook(self, name, callable_or_name, ignore_failure):
        if is_callable(callable_or_name):
            self.hooks[name] = callable_or_name
        else:
            # will raise ImportError on failure
            self.hooks[name] = resolve_name(callable_or_name)

        if ignore_failure:
            self.ignore_hook_failure.append(name)