{"record":{"id":"b170876af61e6711","repo":"composer/composer","slug":"name-could-not-be-downloaded-error","errorCode":null,"errorMessage":"{name} could not be downloaded, {error}","messagePattern":"(.+?) could not be downloaded, (.+?)","errorType":"exception","errorClass":"RuntimeException","httpStatus":null,"severity":"error","filePath":"src/Composer/Downloader/SvnDownloader.php","lineNumber":122,"sourceCode":"    /**\n     * Execute an SVN command and try to fix up the process with credentials\n     * if necessary.\n     *\n     * @param  string            $baseUrl Base URL of the repository\n     * @param  non-empty-list<string> $command SVN command to run\n     * @param  string            $url     SVN url\n     * @param  string            $cwd     Working directory\n     * @param  string            $path    Target for a checkout\n     * @throws \\RuntimeException\n     */\n    protected function execute(PackageInterface $package, string $baseUrl, array $command, string $url, ?string $cwd = null, ?string $path = null): string\n    {\n        $util = new SvnUtil($baseUrl, $this->io, $this->config, $this->process);\n        $util->setCacheCredentials($this->cacheCredentials);\n        try {\n            return $util->execute($command, $url, $cwd, $path, $this->io->isVerbose());\n        } catch (\\RuntimeException $e) {\n            throw new \\RuntimeException(\n                $package->getPrettyName().' could not be downloaded, '.$e->getMessage()\n            );\n        }\n    }\n\n    /**\n     * @inheritDoc\n     */\n    protected function cleanChanges(PackageInterface $package, string $path, bool $update): PromiseInterface\n    {\n        if (null === ($changes = $this->getLocalChanges($package, $path))) {\n            return \\React\\Promise\\resolve(null);\n        }\n\n        if (!$this->io->isInteractive()) {\n            if (true === $this->config->get('discard-changes')) {\n                return $this->discardChanges($path);\n            }","sourceCodeStart":104,"sourceCodeEnd":140,"githubUrl":"https://github.com/composer/composer/blob/6ffc1177404d0c50119c22dde6564a380f4a82c9/src/Composer/Downloader/SvnDownloader.php#L104-L140","documentation":"Thrown by SvnDownloader::execute() (line 119-125) wrapping any RuntimeException from SvnUtil::execute() during svn co/switch. It prefixes the package pretty name and re-throws with the underlying svn error message, covering authentication, network, and repository-access failures.","triggerScenarios":"execute() calls $util->execute($command, $url, ...) for an svn checkout/switch and the underlying util throws — bad credentials, unreachable host, forbidden path, or a malformed svn url.","commonSituations":"SVN credentials not cached/wrong; repository behind a VPN/firewall that is not connected; svn url typo; server-side permission denial.","solutions":["Cache valid SVN credentials or provide them interactively (run svn ls <url> manually to authenticate)","Verify network/VPN connectivity to the SVN server from the environment","Confirm the repository url and path are correct and accessible","Check svn-cache-credentials repository setting if credential caching is the issue"],"exampleFix":"# authenticate and cache credentials once\nsvn ls https://svn.example.com/repo --username me\n# then re-run\ncomposer update","handlingStrategy":"try-catch","validationCode":null,"typeGuard":null,"tryCatchPattern":"try {\n    $downloader->download($package, $path);\n} catch (\\RuntimeException $e) {\n    if (str_contains($e->getMessage(), 'could not be downloaded')) {\n        // surface credential/network guidance; optionally prompt for svn creds and retry\n        handleSvnAccessFailure($package, $e);\n    } else { throw $e; }\n}","preventionTips":["Cache SVN credentials once via 'svn ls <url>' before running composer","Ensure VPN/network connectivity to the SVN server in CI","Verify repository urls and access permissions in the repository definition"],"tags":["svn","vcs","authentication","network"],"analyzedSha":"6ffc1177404d0c50119c22dde6564a380f4a82c9","analyzedAt":"2026-08-07T00:01:08.491Z","schemaVersion":2},"datasetVersion":"2026-08-07T02:17:10.218Z"}