{"record":{"id":"60194b8087bd9668","repo":"jackwener/OpenCLI","slug":"weibo-user-posts-found-post-candidates-but-could-n","errorCode":null,"errorMessage":"weibo user-posts found post candidates but could not extract valid rows","messagePattern":"weibo user-posts found post candidates but could not extract valid rows","errorType":"exception","errorClass":"CommandExecutionError","httpStatus":null,"severity":"error","filePath":"clis/weibo/user-posts.js","lineNumber":213,"sourceCode":"        }\n\n        return [uid, rows, sawList, sawPostCandidates];\n      })()\n    `);\n\n        const payload = unwrapEvaluateResult(evaluateResult);\n        if (payload && !Array.isArray(payload) && typeof payload === 'object' && 'error' in payload) {\n            mapError(payload.error);\n        }\n        if (!Array.isArray(payload) || payload.length !== 4 || !Array.isArray(payload[1])) {\n            throw new CommandExecutionError('weibo user-posts returned malformed extraction payload');\n        }\n        const [resolvedUid, rows, sawList, sawPostCandidates] = payload;\n        if (!sawList && rows.length === 0) {\n            throw new CommandExecutionError('weibo user-posts did not observe a valid posts list');\n        }\n        if (sawPostCandidates && rows.length === 0) {\n            throw new CommandExecutionError('weibo user-posts found post candidates but could not extract valid rows');\n        }\n        if (rows.length === 0) {\n            throw new EmptyResultError('weibo user-posts', 'No Weibo posts found for this user/date range');\n        }\n\n        return rows.slice(0, limit).map((row, index) => ({\n            rank: index + 1,\n            id: String(row.id),\n            mblogid: row.mblogid || '',\n            author: row.author || '',\n            uid: String(row.uid || resolvedUid || ''),\n            text: row.text || '',\n            time: row.time || '',\n            reposts: row.reposts ?? 0,\n            comments: row.comments ?? 0,\n            likes: row.likes ?? 0,\n            pic_count: row.pic_count ?? 0,\n            url: row.url || '',","sourceCodeStart":195,"sourceCodeEnd":231,"githubUrl":"https://github.com/jackwener/OpenCLI/blob/49907e53dc3ade5c223ff0c4c2c2785687cec4e6/clis/weibo/user-posts.js#L195-L231","documentation":"If the extractor saw post candidate elements (sawPostCandidates is true) but could not convert any of them into valid rows, the CLI treats it as an extraction/parse failure rather than an empty account, throwing this CommandExecutionError. The DOM had post-like nodes but every candidate failed field validation.","triggerScenarios":"Weibo markup changed so candidates no longer carry the expected id/timestamp/fields; candidates are placeholders, ads, or loading skeletons; or new post types (new card layouts) fail row mapping.","commonSituations":"Weibo A/B-testing a new feed card layout, promoted/ad posts rendered where organic posts are expected, or partial page renders (skeletons never replaced).","solutions":["Update/upgrade the CLI in case newer selectors handle the new markup.","Retry later — skeleton/placeholder rendering failures are often transient.","Check the failing page in a browser to see if new card types (ads, forwards) appear and adjust extraction for them.","Re-run with a fresh session in case truncated rendering left placeholders in the DOM."],"exampleFix":null,"handlingStrategy":"retry","validationCode":null,"typeGuard":null,"tryCatchPattern":"try {\n  const rows = await runUserPosts(opts);\n} catch (err) {\n  if (err instanceof CommandExecutionError && /could not extract valid rows/.test(err.message)) {\n    await sleep(5000);\n    return runUserPosts(opts); // skeleton/ad rendering often transient\n  }\n  throw err;\n}","preventionTips":["Retry with backoff — placeholders/skeletons are usually transient.","Skip known ad/promoted cards if customizing extraction.","Track Weibo layout A/B changes; update selectors promptly."],"tags":["weibo","selector-mismatch","extraction"],"backgroundTag":"selector-parse-failure","analyzedSha":"49907e53dc3ade5c223ff0c4c2c2785687cec4e6","analyzedAt":"2026-08-29T08:14:47.543Z","schemaVersion":2},"datasetVersion":"2026-08-29T12:17:43.993Z"}