{"record":{"id":"8d6deef904bc2a56","repo":"fish2018/pansou","slug":"s-w-8d6dee","errorCode":null,"errorMessage":"[%s] 解析详情失败: %w","messagePattern":"\\[(.+?)\\] 解析详情失败: %w","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"plugin/yulinshufa/yulinshufa.go","lineNumber":326,"sourceCode":"\tdefer cancel()\n\n\treq, err := http.NewRequestWithContext(ctx, http.MethodGet, item.DetailURL, nil)\n\tif err != nil {\n\t\treturn nil, fmt.Errorf(\"[%s] 创建详情请求失败: %w\", p.Name(), err)\n\t}\n\tp.decorateCommonHeaders(req)\n\treq.Header.Set(\"Referer\", baseURL+\"/\")\n\tp.debugf(\"请求详情: %s\", item.DetailURL)\n\n\tresp, err := p.doRequestWithRetry(p.detailHTTPClient, req, requestMaxRetries)\n\tif err != nil {\n\t\treturn nil, fmt.Errorf(\"[%s] 请求详情失败: %w\", p.Name(), err)\n\t}\n\tdefer resp.Body.Close()\n\n\tdoc, err := p.buildGBKDocument(resp.Body)\n\tif err != nil {\n\t\treturn nil, fmt.Errorf(\"[%s] 解析详情失败: %w\", p.Name(), err)\n\t}\n\n\tresult := p.parseDetailDocument(doc, item)\n\tif result == nil {\n\t\treturn nil, fmt.Errorf(\"[%s] 详情解析为空\", p.Name())\n\t}\n\n\tp.storeInCache(cacheKey, *result)\n\treturn result, nil\n}\n\n// parseDetailDocument 将详情页转为 SearchResult\nfunc (p *YulinshufaPlugin) parseDetailDocument(doc *goquery.Document, item searchItem) *model.SearchResult {\n\tcontentSel := doc.Find(\"div.content\").First()\n\tif contentSel.Length() == 0 {\n\t\treturn nil\n\t}\n","sourceCodeStart":308,"sourceCodeEnd":344,"githubUrl":"https://github.com/fish2018/pansou/blob/beaa56133755a548ebc51b090b3816e2ae044aa6/plugin/yulinshufa/yulinshufa.go#L308-L344","documentation":"Wrapped parse error in YulinshufaPlugin.getDetailResult (plugin/yulinshufa/yulinshufa.go:326): the detail page downloaded but building the GBK-decoded goquery document failed — the body was not decodable HTML in the expected encoding.","triggerScenarios":"Thrown at plugin/yulinshufa/yulinshufa.go:326 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Inspect the raw body and its charset","Update parsing for markup/encoding changes","Skip the detail item on parse failure"],"exampleFix":null,"handlingStrategy":"validation","validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"beaa56133755a548ebc51b090b3816e2ae044aa6","analyzedAt":"2026-09-07T00:31:18.025Z","contentChangedAt":"2026-09-07T00:31:18.025Z","schemaVersion":2},"datasetVersion":"2026-09-15T23:17:13.987Z"}