phacility/phabricator · error · PhutilArgumentUsageException

Specify either a list of objects to affect or "--all", but n

Error message

Specify either a list of objects to affect or "--all", but not both.

What it means

Error "Specify either a list of objects to affect or "--all", but not both." thrown in phacility/phabricator.

Source

Thrown at src/applications/audit/management/PhabricatorAuditManagementWorkflow.php:33

        'wildcard' => true,
        'help' => pht('Update named commits and repositories.'),
      ),
    );
  }

  protected function loadCommitsWithConstraints(PhutilArgumentParser $args) {
    $viewer = $this->getViewer();

    $all = $args->getArg('all');
    $names = $args->getArg('objects');

    if (!$names && !$all) {
      throw new PhutilArgumentUsageException(
        pht(
          'Specify "--all" to affect everything, or a list of specific '.
          'commits or repositories to affect.'));
    } else if ($names && $all) {
      throw new PhutilArgumentUsageException(
        pht(
          'Specify either a list of objects to affect or "--all", but not '.
          'both.'));
    }

    if ($all) {
      $objects = new LiskMigrationIterator(new PhabricatorRepository());
    } else {
      $query = id(new PhabricatorObjectQuery())
        ->setViewer($viewer)
        ->withNames($names);

      $query->execute();

      $objects = array();

      $results = $query->getNamedResults();
      foreach ($names as $name) {

View on GitHub (pinned to 5720a38cfe)

When it happens

Trigger: Thrown at src/applications/audit/management/PhabricatorAuditManagementWorkflow.php:33 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/011a6db1175b5cef. Report an issue: GitHub.