phacility/phabricator · error · PhutilArgumentUsageException

Use "--type <type>" or "--provider <phid>" to specify which

Error message

Use "--type <type>" or "--provider <phid>" to specify which factors to strip, or "--all-types" to strip all factors. Use `bin/auth list-factors` to show the available factor types or `bin/auth list-mfa-providers` to show available providers.

What it means

Error "Use "--type <type>" or "--provider <phid>" to specify which factors to strip, or "--all-types" to strip all factors. Use `bin/auth list-factors` to show the available factor types or `bin/auth list-mfa-providers` to show available providers." thrown in phacility/phabricator.

Source

Thrown at src/applications/auth/management/PhabricatorAuthManagementStripWorkflow.php:105

    } else {
      $users = null;
    }

    $types = $args->getArg('type');
    $provider_phids = $args->getArg('provider');
    $all_types = $args->getArg('all-types');
    if ($types && $all_types) {
      throw new PhutilArgumentUsageException(
        pht(
          'Specify either specific factors with "--type", or all factors with '.
          '"--all-types", but not both.'));
    } else if ($provider_phids && $all_types) {
      throw new PhutilArgumentUsageException(
        pht(
          'Specify either specific factors with "--provider", or all factors '.
          'with "--all-types", but not both.'));
    } else if (!$types && !$all_types && !$provider_phids) {
      throw new PhutilArgumentUsageException(
        pht(
          'Use "--type <type>" or "--provider <phid>" to specify which '.
          'factors to strip, or "--all-types" to strip all factors. '.
          'Use `bin/auth list-factors` to show the available factor types '.
          'or `bin/auth list-mfa-providers` to show available providers.'));
    }

    $type_map = PhabricatorAuthFactor::getAllFactors();

    if ($types) {
      foreach ($types as $type) {
        if (!isset($type_map[$type])) {
          throw new PhutilArgumentUsageException(
            pht(
              'Factor type "%s" is unknown. Use `bin/auth list-factors` to '.
              'get a list of known factor types.',
              $type));
        }

View on GitHub (pinned to 5720a38cfe)

When it happens

Trigger: Thrown at src/applications/auth/management/PhabricatorAuthManagementStripWorkflow.php:105 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/564286c4a4275138. Report an issue: GitHub.