psalm/plugin-laravel
Psalm plugin for Laravel that adds deep framework-aware static analysis plus taint-based security scanning. Detects SQL injection, XSS, SSRF, shell injection, file traversal, and open redirects by tracking user input flows across functions and services.
Emitted when $this->option('name') references an option that is not defined in the command's signature.
If you request an option that doesn't exist in your command's $signature, Laravel will throw a RuntimeException at runtime.
This check catches the mismatch during static analysis.
// Bad — 'verbose-output' is not defined in the signature
class ExportCommand extends Command
{
protected $signature = 'export {file} {--format=csv}';
public function handle(): void
{
$verbose = $this->option('verbose-output'); // InvalidConsoleOptionName
}
}
// Good — option name matches the signature
class ExportCommand extends Command
{
protected $signature = 'export {file} {--format=csv}';
public function handle(): void
{
$format = $this->option('format');
}
}
$signature property of your command for the correct option nameoption() call to match the signature, or add the missing option to the signatureHow can I help you explore Laravel packages today?