phacility/phabricator · error · Exception
The Almanac service for this repository is invalid or could…
Error message
The Almanac service for this repository is invalid or could not be loaded.
What it means
Cluster integrity check in loadAlmanacService: the repository row references an Almanac service PHID, but the omnipotent-user query could not load that service (it was deleted or the PHID is invalid).
Solutions
- Restore or recreate the Almanac service and rebind the repository.
- Clear the repository's Almanac service binding if it should be a local repository.
Defensive patterns
Strategy: validation
When it happens
Trigger: Thrown at src/applications/repository/storage/PhabricatorRepository.php:2542 when the library encounters an invalid state.
Common situations: See trigger scenarios.
AI-assisted analysis of phacility/phabricator@5720a38cfe (2026-08-21).
Data as JSON: /api/errors/15b6432641223fb2.
Report an issue: GitHub.
Appendix: source
Thrown at src/applications/repository/storage/PhabricatorRepository.php:2542
return id(new PhutilURI("{$protocol}://{$address}"))
->setPath($path);
}
public function loadAlmanacService() {
$service_phid = $this->getAlmanacServicePHID();
if (!$service_phid) {
// No service, so this is a local repository.
return null;
}
$service = id(new AlmanacServiceQuery())
->setViewer(PhabricatorUser::getOmnipotentUser())
->withPHIDs(array($service_phid))
->needActiveBindings(true)
->needProperties(true)
->executeOne();
if (!$service) {
throw new Exception(
pht(
'The Almanac service for this repository is invalid or could not '.
'be loaded.'));
}
$service_type = $service->getServiceImplementation();
if (!($service_type instanceof AlmanacClusterRepositoryServiceType)) {
throw new Exception(
pht(
'The Almanac service for this repository does not have the correct '.
'service type.'));
}
return $service;
}
public function markImporting() {
$this->openTransaction();View on GitHub (pinned to 5720a38cfe)