jackwener/OpenCLI · error · CommandExecutionError
Sogou Weixin returned article cards without required title o
Error message
Sogou Weixin returned article cards without required title or URL
What it means
Thrown when Sogou returned result cards but `invalidCount > 0`, i.e. some parsed article cards lacked a required title or URL. The library refuses to return a partial result set to keep output trustworthy. This indicates the extraction found DOM nodes matching the card selector whose fields could not be populated — usually a page-structure drift or ad/promo cards with different markup.
Source
Thrown at clis/weixin/search.js:129
let payload;
try {
await page.goto(searchUrl);
await page.wait(2);
payload = await page.evaluate(buildExtractSearchResultsEvaluate());
}
catch (error) {
const detail = error instanceof Error ? error.message : String(error);
throw new CommandExecutionError('weixin search failed while loading Sogou results', detail);
}
if (!payload || typeof payload !== 'object' || !Array.isArray(payload.rows)) {
throw new CommandExecutionError('weixin search returned an unreadable browser payload', 'Sogou Weixin may have changed its result page structure.');
}
if (payload.blocked) {
throw new CommandExecutionError('Sogou Weixin blocked this search request', 'Open weixin.sogou.com in Chrome and complete any verification before retrying.');
}
if (payload.invalidCount > 0) {
throw new CommandExecutionError('Sogou Weixin returned article cards without required title or URL', 'The result page structure may have changed; refusing to return a partial result set.');
}
const rows = payload.rows;
if (rows.length === 0 && payload.empty) {
throw new EmptyResultError('weixin search', 'Try a different keyword or a different page number.');
}
if (rows.length === 0) {
throw new CommandExecutionError('weixin search did not expose article result cards', 'Sogou Weixin may have changed its selectors or returned a transient shell page.');
}
return rows.slice(0, limit).map((row, index) => ({
rank: (pageNo - 1) * 10 + index + 1,
page: pageNo,
title: row.title,
url: row.url,
summary: row.summary,
publish_time: row.publish_time,
}));View on GitHub (pinned to 49907e53dc)
Solutions
- Retry — if transient (slow rendering), a second attempt often parses cleanly
- Upgrade the CLI so its selectors handle the new card variants
- Try a different page number (e.g. page 2) where ad cards are less common
- Report the failing page markup to the maintainers if it persists
Defensive patterns
Strategy: retry
Try / catch
try { rows = await weixinSearch(q); }
catch (e) { if (String(e.message).includes('without required title')) return retryOnceWithDifferentPage(); throw e; } Prevention
- Retry once before failing — often transient rendering
- Try page 2+ where ad cards are rarer
- Keep CLI updated for new card layouts
When it happens
Trigger: Sogou mixes ad cards or non-article cards into the result list whose selectors don't yield title/url; partial DOM changes break field extraction for some cards; lazy-loaded content not rendered when evaluate ran.
Common situations: Sponsored results appearing on the first page of a popular keyword; Sogou testing a new card layout for a subset of results; slow connections where images/lazy fields haven't populated.
Related errors
- weixin search returned an unreadable browser payload
- Booking.com hotel row is missing stable name/url identity
- Ctrip train page did not render train cards (state=${String(
- Ctrip train DOM extraction returned malformed rows
- Ctrip train cards rendered but parser did not find required
AI-assisted analysis of jackwener/OpenCLI@49907e53dc (2026-08-29).
Data as JSON: /api/errors/75e384cd0ff4165e.
Report an issue: GitHub.