Skip to content

fix(weread): harden reader fallback and search mapping#562

Open
Astro-Han wants to merge 2 commits intojackwener:mainfrom
Astro-Han:worktree-fix-weread-cookie-domain
Open

fix(weread): harden reader fallback and search mapping#562
Astro-Han wants to merge 2 commits intojackwener:mainfrom
Astro-Han:worktree-fix-weread-cookie-domain

Conversation

@Astro-Han
Copy link
Copy Markdown
Contributor

Description

Harden WeRead reader fallback and search URL mapping to avoid silent mismatches when private API auth expires.

Related issue:

Type of Change

  • 🐛 Bug fix
  • ♻️ Refactor

Checklist

  • I ran the checks relevant to this PR
  • I updated tests or docs if needed
  • I included output or screenshots when useful

Documentation (if adding/modifying an adapter)

  • Added doc page under docs/adapters/ (if new adapter)
  • Updated docs/adapters/index.md table (if new adapter)
  • Updated sidebar in docs/.vitepress/config.mts (if new adapter)
  • Updated README.md / README.zh-CN.md when command discoverability changed
  • Used positional args for the command's primary subject unless a named flag is clearly better
  • Normalized expected adapter failures to CliError subclasses instead of raw Error

Screenshots / Output

Validated locally with:

  • npx vitest run src/clis/weread/commands.test.ts src/clis/weread/utils.test.ts src/weread-search-regression.test.ts src/weread-private-api-regression.test.ts
  • npx tsc --noEmit
  • npx tsx src/main.ts weread shelf --limit 1 -f json
  • npx tsx src/main.ts weread book 29196155 -f json
  • npx tsx src/main.ts weread search 文明 --limit 2 -f json

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