{"record":{"id":"531775eab19c86c7","repo":"phacility/phabricator","slug":"you-can-not-list-and-revoke-credentials-with","errorCode":null,"errorMessage":"You can not \"--list\" and revoke credentials (with \"--from\" or \"--everywhere\") in the same operation.","messagePattern":"You can not \"--list\" and revoke credentials \\(with \"--from\" or \"--everywhere\"\\) in the same operation\\.","errorType":"console","errorClass":"PhutilArgumentUsageException","httpStatus":null,"severity":"error","filePath":"src/applications/auth/management/PhabricatorAuthManagementRevokeWorkflow.php","lineNumber":98,"sourceCode":"      $types = $all_types;\n    } else {\n      if (empty($all_types[$type])) {\n        throw new PhutilArgumentUsageException(\n          pht(\n            'Credential type \"%s\" is not valid. Valid credential types '.\n            'are: %s.',\n            $type,\n            implode(', ', array_keys($all_types))));\n      }\n      $types = array($all_types[$type]);\n    }\n\n    $is_everywhere = $args->getArg('everywhere');\n    $from = $args->getArg('from');\n\n    if ($is_list) {\n      if ($from !== null || $is_everywhere) {\n        throw new PhutilArgumentUsageException(\n          pht(\n            'You can not \"--list\" and revoke credentials (with \"--from\" or '.\n            '\"--everywhere\") in the same operation.'));\n      }\n    }\n\n    if ($is_list) {\n      $last_key = last_key($types);\n      foreach ($types as $key => $type) {\n        echo tsprintf(\n          \"**%s** (%s)\\n\\n\",\n          $type->getRevokerKey(),\n          $type->getRevokerName());\n\n        id(new PhutilConsoleBlock())\n          ->addParagraph(tsprintf('%B', $type->getRevokerDescription()))\n          ->draw();\n      }","sourceCodeStart":80,"sourceCodeEnd":116,"githubUrl":"https://github.com/phacility/phabricator/blob/5720a38cfe95b00ca4be5016dd0d2f3195f4fa04/src/applications/auth/management/PhabricatorAuthManagementRevokeWorkflow.php#L80-L116","documentation":"Error \"You can not \"--list\" and revoke credentials (with \"--from\" or \"--everywhere\") in the same operation.\" thrown in phacility/phabricator.","triggerScenarios":"Thrown at src/applications/auth/management/PhabricatorAuthManagementRevokeWorkflow.php:98 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":[],"exampleFix":null,"handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"5720a38cfe95b00ca4be5016dd0d2f3195f4fa04","analyzedAt":"2026-08-21T05:07:25.672Z","schemaVersion":2},"datasetVersion":"2026-08-21T11:28:35.574Z"}