jackwener/OpenCLI · warning · EmptyResultError
facebook marketplace-inbox
Error message
facebook marketplace-inbox
What it means
EmptyResultError thrown when the Facebook Marketplace inbox scrape succeeded but zero conversations were visible in the parsed rows. The CLI surfaces this instead of returning an empty table so the user knows the inbox itself was empty or blocked, not that the command failed silently. It is thrown only after authentication was confirmed (authRequired was false).
Source
Thrown at clis/facebook/marketplace-inbox.js:69
seen.add(key);
const nearby = lines.slice(Math.max(0, i - 2), i + 5).join(' ');
out.push({
buyer,
listing,
snippet,
time,
unread: /Unread/i.test(nearby),
});
}
return { authRequired: false, rows: out };
})()`);
if (result?.authRequired) {
throw new AuthRequiredError('facebook.com', 'Facebook Marketplace inbox requires an active signed-in Facebook session.');
}
const items = Array.isArray(result?.rows) ? result.rows : [];
if (items.length === 0) {
throw new EmptyResultError('facebook marketplace-inbox', 'No Marketplace inbox conversations were visible. Check that Marketplace inbox is available for this account.');
}
return items.slice(0, limit).map((item, index) => ({
index: index + 1,
buyer: item.buyer || '',
listing: item.listing || '',
snippet: item.snippet || '',
time: item.time || '',
unread: Boolean(item.unread),
}));
},
});
export const __test__ = {
normalizeLimit,
};
View on GitHub (pinned to 49907e53dc)
Solutions
- Verify Marketplace inbox is available by opening facebook.com/marketplace/inbox in a browser and confirming conversations are listed
- Log in with an account that has Marketplace enabled and at least one conversation
- Retry in case of slow SPA rendering (rows render after load); re-run the command
- If rows exist in the browser but the CLI still returns empty, the scraping selectors likely changed with Facebook markup - update the evaluate script
Defensive patterns
Strategy: try-catch
Validate before calling
// Ensure an authenticated session exists before invoking // (open the managed browser and confirm you are logged in to facebook.com)
Try / catch
try {
const rows = await runMarketplaceInbox();
} catch (e) {
if (/Marketplace inbox conversations were visible/i.test(e.message)) {
// treat as 'no data' rather than failure: show empty output or prompt user
} else throw e;
} Prevention
- Use an account with Marketplace enabled and existing conversations
- Verify the inbox renders in the browser before scripting
- Re-run once to rule out slow SPA rendering
- Update scrape selectors after Facebook UI changes
When it happens
Trigger: Running `facebook marketplace-inbox` on an account whose Marketplace inbox is empty, hidden, or unavailable; the in-page evaluate script returned {authRequired:false, rows:[]} because no conversation rows matched the selector.
Common situations: New Facebook account without Marketplace; account from a region without Marketplace; Facebook markup change so row selectors no longer match; inbox filtered to a folder with no messages.
Understand the failure class
Background: EmptyResultError / "no results found": when an API or scraper succeeds but returns zero rows — this error's family across 9 libraries.
Related errors
- facebook marketplace-listings
- 1point3acres thread
- 1point3acres user
- amazon ${definition.commandName} did not expose any ranked i
- amazon search did not expose any product cards
AI-assisted analysis of jackwener/OpenCLI@49907e53dc (2026-08-29).
Data as JSON: /api/errors/c5921186882abdc6.
Report an issue: GitHub.