{"record":{"id":"d9e4247851f9ae98","repo":"symfony/process","slug":"unable-to-find-the-php-executable","errorCode":null,"errorMessage":"Unable to find the PHP executable.","messagePattern":"Unable to find the PHP executable\\.","errorType":"exception","errorClass":"RuntimeException","httpStatus":null,"severity":"error","filePath":"PhpProcess.php","lineNumber":67,"sourceCode":"            $script = null;\n        }\n\n        parent::__construct($php, $cwd, $env, $script, $timeout);\n    }\n\n    public static function fromShellCommandline(string $command, ?string $cwd = null, ?array $env = null, mixed $input = null, ?float $timeout = 60): static\n    {\n        throw new LogicException(\\sprintf('The \"%s()\" method cannot be called when using \"%s\".', __METHOD__, self::class));\n    }\n\n    /**\n     * @param (callable('out'|'err', string):void)|null $callback\n     * @param EnvArray                                  $env\n     */\n    public function start(?callable $callback = null, array $env = []): void\n    {\n        if (null === $this->getCommandLine()) {\n            throw new RuntimeException('Unable to find the PHP executable.');\n        }\n\n        parent::start($callback, $env);\n    }\n}\n","sourceCodeStart":49,"sourceCodeEnd":73,"githubUrl":"https://github.com/symfony/process/blob/99b85026db14a68f02c6f3eeb01a1170ca25c491/PhpProcess.php#L49-L73","documentation":"Thrown at the start of PhpProcess::start when the command line is empty because no PHP binary could be located: PhpExecutableFinder::find() returned false during construction and no explicit executable was provided.","triggerScenarios":"Thrown at PhpProcess.php:67 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Pass an explicit PHP binary path via the $php constructor argument","Ensure the PHP executable is on PATH or point PHP_BINARY appropriately","Verify the runtime environment where the process is spawned"],"exampleFix":null,"handlingStrategy":"fallback","validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"99b85026db14a68f02c6f3eeb01a1170ca25c491","analyzedAt":"2026-09-14T11:23:33.683Z","contentChangedAt":"2026-09-14T11:23:33.683Z","schemaVersion":2},"datasetVersion":"2026-09-16T09:17:16.951Z"}