phacility/phabricator · error · Exception
Attempting to build a repository command (for repository "%s
Error message
Attempting to build a repository command (for repository "%s") as device, but this host ("%s") is not configured as a cluster device. What it means
Error "Attempting to build a repository command (for repository "%s") as device, but this host ("%s") is not configured as a cluster device." thrown in phacility/phabricator.
Source
Thrown at src/applications/diffusion/protocol/DiffusionCommandEngine.php:192
private function newCommonEnvironment() {
$repository = $this->getRepository();
$env = array();
// NOTE: Force the language to "en_US.UTF-8", which overrides locale
// settings. This makes stuff print in English instead of, e.g., French,
// so we can parse the output of some commands, error messages, etc.
$env['LANG'] = 'en_US.UTF-8';
// Propagate PHABRICATOR_ENV explicitly. For discussion, see T4155.
$env['PHABRICATOR_ENV'] = PhabricatorEnv::getSelectedEnvironmentName();
$as_device = $this->getConnectAsDevice();
$credential_phid = $this->getCredentialPHID();
if ($as_device) {
$device = AlmanacKeys::getLiveDevice();
if (!$device) {
throw new Exception(
pht(
'Attempting to build a repository command (for repository "%s") '.
'as device, but this host ("%s") is not configured as a cluster '.
'device.',
$repository->getDisplayName(),
php_uname('n')));
}
if ($credential_phid) {
throw new Exception(
pht(
'Attempting to build a repository command (for repository "%s"), '.
'but the CommandEngine is configured to connect as both the '.
'current cluster device ("%s") and with a specific credential '.
'("%s"). These options are mutually exclusive. Connections must '.
'authenticate as one or the other, not both.',
$repository->getDisplayName(),
$device->getName(),View on GitHub (pinned to 5720a38cfe)
When it happens
Trigger: Thrown at src/applications/diffusion/protocol/DiffusionCommandEngine.php:192 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/24cd8fc675556060.
Report an issue: GitHub.