Call a function, resolving any type-hinted arguments.

def call(self, func, *args, **kwargs):
        """
        Call a function, resolving any type-hinted arguments.
        """
        guessed_kwargs = self._guess_kwargs(func)
        for key, val in guessed_kwargs.items():
            kwargs.setdefault(key, val)
        try:
            return func(*args, **kwargs)
        except TypeError as exc:
            msg = (
                "tried calling function %r but failed, probably "
                "because it takes arguments that cannot be resolved"
            ) % func
            raise DiayException(msg) from exc