symfony/symfony — Issue #2358: Strange behaviour with some non-existent commands
Author: alessandro1997
Created: 2011-10-08 17:11:49+00:00
State: open

I just noticed something strange.

I was working with the console, trying to execute **doctrine:database:create**, so instead, I've typed **d:d:c**. Here's what I got:

[ErrorException]
Notice: Undefined index: d:d in /home/alessandro/projects/Papers/vendor/symfony/src/Symfony/Component/Console/Application.php line 491

This happens with some other commands, like **a:b:c**. However **b:c:d** throws an **InvalidArgumentException** as expected:

[InvalidArgumentException]
There are no commands defined in the "b:c" namespace.

I think the console shouldn't throw any PHP error at all, and I don't understand why this happens only with some namespaces.