{"record":{"id":"fe3a687e212449a2","repo":"cli/cli","slug":"failed-to-create-tuf-client-v-fe3a68","errorCode":null,"errorMessage":"failed to create TUF client: %v","messagePattern":"failed to create TUF client: (.+?)","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"pkg/cmd/attestation/verification/sigstore.go","lineNumber":343,"sourceCode":"\tif len(trustedRoot.RekorLogs()) > 0 {\n\t\tverifierConfig = append(verifierConfig, verify.WithTransparencyLog(1))\n\t}\n\n\tgv, err := verify.NewVerifier(trustedRoot, verifierConfig...)\n\tif err != nil {\n\t\treturn nil, fmt.Errorf(\"failed to create custom verifier: %v\", err)\n\t}\n\n\treturn gv, nil\n}\n\nfunc newGitHubVerifier(trustDomain string, tufMetadataDir o.Option[string], hc *http.Client) (*verify.Verifier, error) {\n\tvar tr string\n\n\topts := GitHubTUFOptions(tufMetadataDir, hc)\n\tclient, err := tuf.New(opts)\n\tif err != nil {\n\t\treturn nil, fmt.Errorf(\"failed to create TUF client: %v\", err)\n\t}\n\n\tif trustDomain == \"\" {\n\t\ttr = \"trusted_root.json\"\n\t} else {\n\t\ttr = fmt.Sprintf(\"%s.trusted_root.json\", trustDomain)\n\t}\n\tjsonBytes, err := client.GetTarget(tr)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\ttrustedRoot, err := root.NewTrustedRootFromJSON(jsonBytes)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\treturn newGitHubVerifierWithTrustedRoot(trustedRoot)\n}\n","sourceCodeStart":325,"sourceCodeEnd":361,"githubUrl":"https://github.com/cli/cli/blob/0eeec0b92edbe70199f9768522f831d3534f41ad/pkg/cmd/attestation/verification/sigstore.go#L325-L361","documentation":"Error \"failed to create TUF client: %v\" thrown in cli/cli.","triggerScenarios":"Thrown at pkg/cmd/attestation/verification/sigstore.go:343 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Check network access to the TUF repository and retry; clearing the local TUF cache may also help."],"exampleFix":null,"handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"0eeec0b92edbe70199f9768522f831d3534f41ad","analyzedAt":"2026-08-15T12:31:05.478Z","schemaVersion":2},"datasetVersion":"2026-08-15T22:17:37.221Z"}