jackwener/OpenCLI · error · EmptyResultError
No turns were visible after navigating to ${target}.
Error message
No turns were visible after navigating to ${target}. What it means
The gemini detail command navigates to the resolved conversation URL and then extracts visible turns; if none are rendered, it throws EmptyResultError stating no turns were visible at that target. This usually means the page loaded but Gemini did not render any conversation content (auth wall, slow render, or empty/invalid conversation). It protects callers from returning an empty table that looks like a successful but dataless result.
Source
Thrown at clis/gemini/detail.js:71
name: 'detail',
access: 'read',
description: 'Open a Gemini web conversation by id, URL, or sidebar title and read its turns',
domain: GEMINI_DOMAIN,
strategy: Strategy.COOKIE,
browser: true,
siteSession: 'persistent',
navigateBefore: false,
args: [
{ name: 'id', positional: true, required: true, help: 'Conversation id, /app/<id> URL, or sidebar title' },
],
columns: ['Index', 'Role', 'Text'],
func: async (page, kwargs) => {
await ensureGeminiPage(page);
const target = await resolveTargetUrl(page, kwargs?.id);
await page.goto(target, { waitUntil: 'load', settleMs: 2500 });
const turns = await getGeminiVisibleTurns(page);
if (!Array.isArray(turns) || turns.length === 0) {
throw new EmptyResultError(
'gemini detail',
`No turns were visible after navigating to ${target}.`,
);
}
return turns.map((t, idx) => ({
Index: idx + 1,
Role: t.Role || 'System',
Text: t.Text || '',
}));
},
});
View on GitHub (pinned to 49907e53dc)
Solutions
- Re-run the command after confirming the Gemini page is loaded and signed in (e.g. run `opencli gemini history` first to refresh/verify session)
- Increase the settle time or retry on a faster connection so turns finish rendering
- Open the target URL manually in the browser to verify the conversation exists and is accessible
- Sign in again if the session expired, then retry
Example fix
// before opencli gemini detail --id abc123def4567890 // blank page, session expired // after opencli gemini history // ensures signed-in page state opencli gemini detail --id abc123def4567890
Defensive patterns
Strategy: retry
Validate before calling
const hist = await run(['gemini','history','--limit','1']);
if (!hist.length) throw new Error('Gemini sidebar empty or session invalid; sign in first'); Type guard
function hasTurns(t){ return Array.isArray(t) && t.length > 0; } Try / catch
try {
return await run(['gemini','detail','--id', id]);
} catch (e) {
if (String(e.message).startsWith('No turns were visible')) {
await sleep(3000);
return await run(['gemini','detail','--id', id]); // retry once for slow render
}
throw e;
} Prevention
- Run a session-touching command (history) before detail to ensure sign-in
- Retry once after a delay on slow networks before giving up
- Verify the conversation URL opens manually in the browser
When it happens
Trigger: Navigating to a conversation URL where the chat body fails to render: session expired/signed out, Gemini shows a consent or error page, the conversation id points to a deleted chat rendering blank, or rendering exceeds the fixed settle time (2500ms) on a slow connection.
Common situations: Expired Google session redirecting to sign-in; very slow network where turns render after the 2.5s settle; conversation deleted in another tab; region/consent interstitials blocking the app UI.
Related errors
- 'gemini read','No Gemini conversation links were visible in
- No prices returned for train_no=${trainNo} ${fromStation.nam
- No 12306 stations match "${keyword}"
- No posts found in this Band
- CoinGecko returned no category data.
AI-assisted analysis of jackwener/OpenCLI@49907e53dc (2026-08-29).
Data as JSON: /api/errors/41ecd25d90ee9c6b.
Report an issue: GitHub.