{"record":{"id":"a09147587898651d","repo":"phacility/phabricator","slug":"the-name-s-is-not-a-valid-repository-short-name","errorCode":null,"errorMessage":"The name \"%s\" is not a valid repository short name. Repository short names must not be longer than 64 characters.","messagePattern":"The name \"(.+?)\" is not a valid repository short name\\. Repository short names must not be longer than 64 characters\\.","errorType":"validation","errorClass":"Exception","httpStatus":null,"severity":"error","filePath":"src/applications/repository/storage/PhabricatorRepository.php","lineNumber":379,"sourceCode":"  public static function isValidRepositorySlug($slug) {\n    try {\n      self::assertValidRepositorySlug($slug);\n      return true;\n    } catch (Exception $ex) {\n      return false;\n    }\n  }\n\n  public static function assertValidRepositorySlug($slug) {\n    if (!strlen($slug)) {\n      throw new Exception(\n        pht(\n          'The empty string is not a valid repository short name. '.\n          'Repository short names must be at least one character long.'));\n    }\n\n    if (strlen($slug) > 64) {\n      throw new Exception(\n        pht(\n          'The name \"%s\" is not a valid repository short name. Repository '.\n          'short names must not be longer than 64 characters.',\n          $slug));\n    }\n\n    if (preg_match('/[^a-zA-Z0-9._-]/', $slug)) {\n      throw new Exception(\n        pht(\n          'The name \"%s\" is not a valid repository short name. Repository '.\n          'short names may only contain letters, numbers, periods, hyphens '.\n          'and underscores.',\n          $slug));\n    }\n\n    if (!preg_match('/^[a-zA-Z0-9]/', $slug)) {\n      throw new Exception(\n        pht(","sourceCodeStart":361,"sourceCodeEnd":397,"githubUrl":"https://github.com/phacility/phabricator/blob/5720a38cfe95b00ca4be5016dd0d2f3195f4fa04/src/applications/repository/storage/PhabricatorRepository.php#L361-L397","documentation":"Fires from assertValidRepositorySlug when the proposed repository short name (callsign-free slug) exceeds 64 bytes. Called from both transaction validation and the boolean isValidRepositorySlug wrapper; the offending name is interpolated and the edit/lookup is rejected.","triggerScenarios":"Thrown at src/applications/repository/storage/PhabricatorRepository.php:379 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Shorten the repository short name to 64 characters or fewer."],"exampleFix":null,"handlingStrategy":"validation","validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"5720a38cfe95b00ca4be5016dd0d2f3195f4fa04","analyzedAt":"2026-08-21T05:07:25.672Z","contentChangedAt":"2026-08-21T05:07:25.672Z","schemaVersion":2},"datasetVersion":"2026-09-23T08:17:48.524Z"}