Do not display short exception trace for built-in console exceptions
This commit is contained in:
parent
c97c6d48b3
commit
47b1106868
@ -761,7 +761,9 @@ class Application
|
||||
}
|
||||
|
||||
$messages = array();
|
||||
if (!$e instanceof ExceptionInterface || OutputInterface::VERBOSITY_VERBOSE <= $output->getVerbosity()) {
|
||||
$messages[] = sprintf('<comment>%s</comment>', OutputFormatter::escape(sprintf('In %s line %s:', basename($e->getFile()) ?: 'n/a', $e->getLine() ?: 'n/a')));
|
||||
}
|
||||
$messages[] = $emptyLine = sprintf('<error>%s</error>', str_repeat(' ', $len));
|
||||
if ('' === $message || OutputInterface::VERBOSITY_VERBOSE <= $output->getVerbosity()) {
|
||||
$messages[] = sprintf('<error>%s%s</error>', $title, str_repeat(' ', max(0, $len - Helper::strlen($title))));
|
||||
|
@ -1,5 +1,4 @@
|
||||
|
||||
In Application.php line 615:
|
||||
|
||||
Command "foo" is not defined.
|
||||
|
||||
|
@ -1,5 +1,4 @@
|
||||
|
||||
In ArrayInput.php line 178:
|
||||
|
||||
The "--foo" option does not exist.
|
||||
|
||||
|
@ -1,5 +1,4 @@
|
||||
|
||||
In Application.php line 615:
|
||||
|
||||
Command "foo" is not define
|
||||
d.
|
||||
|
Reference in New Issue
Block a user