Symfony version(s) affected
6.1.0
Description
Not a big deal, but I'm reporting it anyway:
When using the new #AsCommand() attribute, and the description contains a "parameter-like" substring (i.e. something between two % signs), then running php bin/console list results in:
[critical] Error thrown while running command "list". Message: "The parameter "a\" must be defined."
In App_KernelDevDebugContainer.php line 370:
The parameter "a\" must be defined.
How to reproduce
use Symfony\Component\Console\Attribute\AsCommand;
use Symfony\Component\Console\Command\Command;
#[AsCommand(name: 'app:foo', description: '%a%')]
final class FooCommand extends Command
{
}
Possible Solution
Don't parse the description at all (i.e. output it as-is), or provide some escaping mechanism.
Additional Context
No response
Symfony version(s) affected
6.1.0
Description
Not a big deal, but I'm reporting it anyway:
When using the new
#AsCommand()attribute, and thedescriptioncontains a "parameter-like" substring (i.e. something between two%signs), then runningphp bin/console listresults in:How to reproduce
Possible Solution
Don't parse the
descriptionat all (i.e. output it as-is), or provide some escaping mechanism.Additional Context
No response