Skip to content

[codex] Fix Xiaohongshu search navigation#2011

Draft
ppop123 wants to merge 1 commit into
jackwener:mainfrom
ppop123:codex/fix-xhs-search-route
Draft

[codex] Fix Xiaohongshu search navigation#2011
ppop123 wants to merge 1 commit into
jackwener:mainfrom
ppop123:codex/fix-xhs-search-route

Conversation

@ppop123

@ppop123 ppop123 commented Jun 24, 2026

Copy link
Copy Markdown

Summary

  • submit Xiaohongshu searches through the visible web search box instead of direct-linking the search results URL
  • wait until the page reaches search_result / search_result_ai before extracting note cards
  • surface Xiaohongshu security restriction pages (安全限制, 300011, Account abnormal) as typed command errors instead of empty results

Root Cause

xiaohongshu/search navigated directly to /search_result?...source=web_search_result_notes. In current Xiaohongshu web sessions that route can redirect to /website-login/error with 300011 Account abnormal, while manual searches from the web UI still work. The adapter also treated non-result pages as empty data, so callers saw (no data) instead of a clear failure.

Validation

  • npx vitest run --project adapter clis/xiaohongshu/search.test.js
  • npm run typecheck

Local Live Check

Before preparing this PR, I verified the same change against a logged-in local Chrome/OpenCLI Adapter session with:

opencli xiaohongshu search "增额寿险靠谱吗" --limit 5

The command returned relevant search results instead of (no data).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant