{"record":{"id":"c79009ed3cb9934f","repo":"phacility/phabricator","slug":"no-commit-s-in-this-repository","errorCode":null,"errorMessage":"No commit \"%s\" in this repository.","messagePattern":"No commit \"(.+?)\" in this repository\\.","errorType":"exception","errorClass":"Exception","httpStatus":null,"severity":"error","filePath":"src/applications/diffusion/query/lowlevel/DiffusionLowLevelParentsQuery.php","lineNumber":83,"sourceCode":"      // missing parents; ignore it.\n      if (preg_match('/^0+\\z/', $value)) {\n        unset($hashes[$key]);\n      }\n    }\n\n    return $hashes;\n  }\n\n  private function loadSubversionParents() {\n    $repository = $this->getRepository();\n    $identifier = $this->identifier;\n\n    $refs = id(new DiffusionCachedResolveRefsQuery())\n      ->setRepository($repository)\n      ->withRefs(array($identifier))\n      ->execute();\n    if (!$refs) {\n      throw new Exception(\n        pht(\n          'No commit \"%s\" in this repository.',\n          $identifier));\n    }\n\n    $n = (int)$identifier;\n    if ($n > 1) {\n      $ids = array($n - 1);\n    } else {\n      $ids = array();\n    }\n\n    return $ids;\n  }\n\n}\n","sourceCodeStart":65,"sourceCodeEnd":100,"githubUrl":"https://github.com/phacility/phabricator/blob/5720a38cfe95b00ca4be5016dd0d2f3195f4fa04/src/applications/diffusion/query/lowlevel/DiffusionLowLevelParentsQuery.php#L65-L100","documentation":"DiffusionLowLevelParentsQuery::loadSubversionParents first resolves the requested revision identifier through DiffusionCachedResolveRefsQuery. For Subversion, identifiers are revision numbers; if the identifier resolves to no known commit in that repository, the cached lookup returns nothing and this exception reports the missing commit.","triggerScenarios":"Calling the parents query (commit page or history rendering) for an SVN revision that does not exist: a revision number beyond HEAD, a typo like r99999, a Git-style hash passed to an SVN repository, or a revision the importer has not discovered yet.","commonSituations":"Newly created hosted SVN repositories with zero commits; imports still in progress; interrupted svnadmin load; external tracker links pointing at revisions that were never loaded.","solutions":["Confirm the revision exists in the repository itself: svn log -r <n> <repository-uri>","Force discovery forward: bin/repository update <callsign>, or wait for/poke the repository daemon","Verify you resolved the correct repository (callsign routing), especially with multiple SVN repos","If the repository is empty, make the first commit or let the initial import finish"],"exampleFix":null,"handlingStrategy":"validation","validationCode":"// Resolve the identifier before asking for parents\n$refs = id(new DiffusionCachedResolveRefsQuery())\n  ->setRepository($repository)\n  ->withRefs(array($identifier))\n  ->execute();\nif (empty($refs[$identifier])) {\n  // render a 404 'revision not found' response instead of throwing\n}","typeGuard":"function isSvnRevisionIdentifier($raw) {\n  return (bool)preg_match('/^r?[1-9][0-9]*$/', trim($raw));\n}","tryCatchPattern":"try {\n  $parents = id(new DiffusionLowLevelParentsQuery())\n    ->setRepository($repository)\n    ->withIdentifier($identifier)\n    ->execute();\n} catch (Exception $ex) {\n  if (preg_match('/^No commit /', $ex->getMessage())) {\n    return new Aphront404Response();\n  }\n  throw $ex;\n}","preventionTips":["Validate revision numbers against repository HEAD before building parent links","Keep repository discovery running so cached ref lookups stay warm","Never reuse Git-style hashes as SVN identifiers"],"tags":["svn","diffusion","commit-not-found"],"backgroundTag":"commit-not-found","analyzedSha":"5720a38cfe95b00ca4be5016dd0d2f3195f4fa04","analyzedAt":"2026-08-21T05:07:25.672Z","schemaVersion":2},"datasetVersion":"2026-08-21T11:28:35.574Z"}