{"record":{"id":"3df9ff332526424d","repo":"cli/cli","slug":"failed-to-prompt-w-3df9ff","errorCode":null,"errorMessage":"failed to prompt: %w","messagePattern":"failed to prompt: %w","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"pkg/cmd/codespace/delete.go","lineNumber":236,"sourceCode":"}\n\ntype surveyPrompter struct{}\n\nfunc (p *surveyPrompter) Confirm(message string) (bool, error) {\n\tprompter := &Prompter{}\n\tvar confirmed struct {\n\t\tConfirmed bool\n\t}\n\tq := []*survey.Question{\n\t\t{\n\t\t\tName: \"confirmed\",\n\t\t\tPrompt: &survey.Confirm{\n\t\t\t\tMessage: message,\n\t\t\t},\n\t\t},\n\t}\n\tif err := prompter.Ask(q, &confirmed); err != nil {\n\t\treturn false, fmt.Errorf(\"failed to prompt: %w\", err)\n\t}\n\n\treturn confirmed.Confirmed, nil\n}\n","sourceCodeStart":218,"sourceCodeEnd":241,"githubUrl":"https://github.com/cli/cli/blob/0eeec0b92edbe70199f9768522f831d3534f41ad/pkg/cmd/codespace/delete.go#L218-L241","documentation":"Error \"failed to prompt: %w\" thrown in cli/cli.","triggerScenarios":"Thrown at pkg/cmd/codespace/delete.go:236 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Run in an interactive terminal, or pass flags to avoid prompting."],"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"}