{"id":"c7e787ad2f8c457b","repo":"docker/cli","slug":"error-removing-signer-from-s","errorCode":null,"errorMessage":"error removing signer from: %s","messagePattern":"error removing signer from: (.+?)","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"cmd/docker-trust/trust/signer_remove.go","lineNumber":52,"sourceCode":"\t\t},\n\t\tDisableFlagsInUseLine: true,\n\t}\n\tflags := cmd.Flags()\n\tflags.BoolVarP(&options.forceYes, \"force\", \"f\", false, \"Do not prompt for confirmation before removing the most recent signer\")\n\treturn cmd\n}\n\nfunc removeSigner(ctx context.Context, dockerCLI command.Cli, options signerRemoveOptions) error {\n\tvar errRepos []string\n\tfor _, repo := range options.repos {\n\t\t_, _ = fmt.Fprintf(dockerCLI.Out(), \"Removing signer \\\"%s\\\" from %s...\\n\", options.signer, repo)\n\t\tif _, err := removeSingleSigner(ctx, dockerCLI, repo, options.signer, options.forceYes); err != nil {\n\t\t\t_, _ = fmt.Fprintln(dockerCLI.Err(), err.Error()+\"\\n\")\n\t\t\terrRepos = append(errRepos, repo)\n\t\t}\n\t}\n\tif len(errRepos) > 0 {\n\t\treturn fmt.Errorf(\"error removing signer from: %s\", strings.Join(errRepos, \", \"))\n\t}\n\treturn nil\n}\n\nfunc isLastSignerForReleases(roleWithSig data.Role, allRoles []client.RoleWithSignatures) (bool, error) {\n\tvar releasesRoleWithSigs client.RoleWithSignatures\n\tfor _, role := range allRoles {\n\t\tif role.Name == releasesRoleTUFName {\n\t\t\treleasesRoleWithSigs = role\n\t\t\tbreak\n\t\t}\n\t}\n\tcounter := len(releasesRoleWithSigs.Signatures)\n\tif counter == 0 {\n\t\treturn false, errors.New(\"all signed tags are currently revoked, use docker trust sign to fix\")\n\t}\n\tfor _, signature := range releasesRoleWithSigs.Signatures {\n\t\tfor _, key := range roleWithSig.KeyIDs {","sourceCodeStart":34,"sourceCodeEnd":70,"githubUrl":"https://github.com/docker/cli/blob/e9452d6e785f6e365712b9d71bd7517591773c86/cmd/docker-trust/trust/signer_remove.go#L34-L70","documentation":"Error \"error removing signer from: %s\" thrown in docker/cli.","triggerScenarios":"Thrown at cmd/docker-trust/trust/signer_remove.go:52 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":[],"exampleFix":null,"handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"analyzedSha":"e9452d6e785f6e365712b9d71bd7517591773c86","analyzedAt":"2026-08-01T07:09:22.474Z","schemaVersion":2}