jackwener/OpenCLI · error · CommandExecutionError
Jike user page did not expose the expected data script
Error message
Jike user page did not expose the expected data script
What it means
CommandExecutionError thrown when the inline browser script that extracts Jike user data reports reason 'missing-data-script', meaning the page HTML contained no recognizable script embedding the post data. The library throws this instead of returning an empty list so callers know the page structure changed or the wrong page was served.
Source
Thrown at clis/jike/user.js:58
}
})()
`);
if (Array.isArray(data)) {
if (data.length === 0) {
throw new EmptyResultError('jike user', `No posts were returned for user ${args.username}. Confirm the username and login state.`);
}
return data.slice(0, limit).map((item) => ({
id: item.id ?? '',
content: item.content ?? '',
type: item.type ?? '',
likes: item.likes ?? 0,
comments: item.comments ?? 0,
time: item.time ?? '',
url: `https://web.okjike.com/originalPost/${item.id ?? ''}`,
}));
}
if (data?.reason === 'missing-data-script') {
throw new CommandExecutionError('Jike user page did not expose the expected data script');
}
if (data?.reason === 'parse-error') {
throw new CommandExecutionError(`Failed to parse Jike user data: ${data.message || 'unknown error'}`);
}
throw new CommandExecutionError('Jike user returned an unreadable payload');
},
});
View on GitHub (pinned to 49907e53dc)
Solutions
- Open the profile URL in a normal browser to check whether a captcha or login wall appears and complete it
- Retry the command — the failure is often transient (interstitial page)
- Update the CLI in case a newer version tracks a Jike page-structure change
- Inspect the saved/printed HTML to locate the new script tag and adjust the extraction selector
Defensive patterns
Strategy: retry
Try / catch
try {
const posts = await jikeUser({ username, limit });
} catch (e) {
if (String(e.message).includes('data script')) {
// transient page interstitial — retry once after delay
await sleep(2000);
return jikeUser({ username, limit });
}
throw e;
} Prevention
- Retry after a short delay — anti-bot/interstitial pages are often transient
- Keep the CLI updated for Jike page-structure changes
- Check the page manually in a browser when it persists
- Avoid running behind proxies that inject or strip page content
When it happens
Trigger: Executing `jike user` when the fetched web.okjike.com profile page does not contain the expected data-bearing <script> tag: Jike redesigned their page, a bot-check/verification page was served, or a network error page replaced the profile.
Common situations: Jike frontend update changing script identifiers; CDN or anti-bot interstitial (captcha) page returned instead of the profile; offline or captive-network environment serving an error page.
Related errors
- Not a git repository
- Working tree not clean: ${status}
- Ctrip attraction DOM extraction returned malformed rows
- Ctrip attraction links rendered but parser did not find requ
- Ctrip bus DOM extraction returned malformed rows
AI-assisted analysis of jackwener/OpenCLI@49907e53dc (2026-08-29).
Data as JSON: /api/errors/2f4ea97800278ba4.
Report an issue: GitHub.