private function assertCallableIsValid($callable): void
    {
        try {
            $this->console->getContainer();
        } catch (LogicException $e) {
            if ($this->isStaticCallToNonStaticMethod($callable)) {
                [$class, $method] = $callable;

                $message = "['{$class}', '{$method}'] is not a callable because '{$method}' is a static method.";
                $message .= " Either use [new {$class}(), '{$method}'] or configure a dependency injection container that supports autowiring.";

                throw new InvalidArgumentException($message);
            }
        }
    }