phacility/phabricator · error · Exception

This repository (" ") is not a Subversion repository. Use "…

Error message

This repository ("%s") is not a Subversion repository. Use "%s" to interact with this repository.

What it means

raiseWrongVCSException() is the SVN workflow's mismatch message: loadRepositoryWithPath() with REPOSITORY_TYPE_SVN matched a repository, but it is Git or Mercurial. The text names the repository and its actual version control system so the caller knows which client to use instead.

Solutions

  1. Interact with the repository using the client matching its real VCS (git/hg URIs from the repository page)
  2. If the repository itself was miscreated, re-create it with the correct VCS type (VCS cannot be changed in place)
  3. Retire stale client-side checkouts that still point at the old layout
Defensive patterns

Strategy: validation

Validate before calling

if (!$repository->isSVN()) {
  // route to the git/hg workflow instead of svnserve
}

Type guard

function isSVNRepository(PhabricatorRepository $repository) {
  return $repository->isSVN();
}

Prevention

When it happens

Trigger: Running svn against a repository hosted as Git or Mercurial - usually because the svn+ssh URL path maps to that repository; or the repository was created with the wrong VCS type.

Common situations: Copy-pasting the wrong clone URI; repositories migrated from SVN to Git while old checkouts persist; an admin picked the wrong VCS when creating the repository.

Related errors


AI-assisted analysis of phacility/phabricator@5720a38cfe (2026-08-21). Data as JSON: /api/errors/9cf20c07a3386ef9. Report an issue: GitHub.

Appendix: source

Thrown at src/applications/diffusion/ssh/DiffusionSubversionServeSSHWorkflow.php:457

    if (strncmp($uri, $internal, strlen($internal)) === 0) {
      $uri = $external.substr($uri, strlen($internal));
    }

    return $uri;
  }

  private function normalizeSVNPath($path) {
    // Subversion normalizes redundant slashes internally, so normalize them
    // here as well to make sure things match up.
    $path = preg_replace('(/+)', '/', $path);

    return $path;
  }

  protected function raiseWrongVCSException(
    PhabricatorRepository $repository) {
    throw new Exception(
      pht(
        'This repository ("%s") is not a Subversion repository. Use "%s" to '.
        'interact with this repository.',
        $repository->getDisplayName(),
        $repository->getVersionControlSystem()));
  }

}

View on GitHub (pinned to 5720a38cfe)