phacility/phabricator · error · Exception
Configuration must be a list of project color…
Error message
Configuration must be a list of project color specifications.
What it means
Raised in PhabricatorProjectIconSet::validateColorConfiguration when the config value is not an array. Color configuration must be a list of color specification dictionaries; the invalid input is a non-array stored config.
Solutions
- Set project.colors to a list of dictionaries with key and name fields.
- Remove the option to fall back to the builtin color set if custom colors are not needed.
Defensive patterns
Strategy: type-guard
When it happens
Trigger: Thrown at src/applications/project/icon/PhabricatorProjectIconSet.php:436 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/26690db0186dc0f3.
Report an issue: GitHub.
Appendix: source
Thrown at src/applications/project/icon/PhabricatorProjectIconSet.php:436
),
array(
'key' => PHUITagView::COLOR_PINK,
'name' => pht('Pink'),
),
array(
'key' => PHUITagView::COLOR_GREY,
'name' => pht('Grey'),
),
array(
'key' => PHUITagView::COLOR_CHECKERED,
'name' => pht('Checkered'),
),
);
}
public static function validateColorConfiguration($config) {
if (!is_array($config)) {
throw new Exception(
pht('Configuration must be a list of project color specifications.'));
}
$available_keys = self::getAvailableColorKeys();
$available_keys = array_fuse($available_keys);
foreach ($config as $idx => $value) {
if (!is_array($value)) {
throw new Exception(
pht(
'Value for index "%s" should be a dictionary.',
$idx));
}
PhutilTypeSpec::checkMap(
$value,
array(
'key' => 'string',View on GitHub (pinned to 5720a38cfe)