phacility/phabricator · error · PhutilArgumentUsageException

Specify a item with %s.

Error message

Specify a item with %s.

What it means

Error "Specify a item with %s." thrown in phacility/phabricator.

Source

Thrown at src/applications/nuance/management/NuanceManagementWorkflow.php:70

      throw new PhutilArgumentUsageException($message);
    } else if (count($sources) > 1) {
      $message = pht(
        'More than one source matches "%s". Choose a narrower query, or '.
        'use an ID or PHID to select a source. Matching sources: %s.',
        $source,
        implode(', ', mpull($sources, 'getName')));

      throw new PhutilArgumentUsageException($message);
    }

    return head($sources);
  }

  protected function loadITem(PhutilArgumentParser $argv, $key) {
    $item = $argv->getArg($key);
    if (!strlen($item)) {
      throw new PhutilArgumentUsageException(
        pht(
          'Specify a item with %s.',
          '--'.$key));
    }

    $query = id(new NuanceItemQuery())
      ->setViewer($this->getViewer())
      ->setRaisePolicyExceptions(true);

    $type_unknown = PhabricatorPHIDConstants::PHID_TYPE_UNKNOWN;

    if (ctype_digit($item)) {
      $kind = 'id';
      $query->withIDs(array($item));
    } else if (phid_get_type($item) !== $type_unknown) {
      $kind = 'phid';
      $query->withPHIDs($item);
    } else {

View on GitHub (pinned to 5720a38cfe)

When it happens

Trigger: Thrown at src/applications/nuance/management/NuanceManagementWorkflow.php:70 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/6b5a4ef94cc1ae94. Report an issue: GitHub.