feat(jisilu): add timeline and question adapters for jisilu.cn#139
feat(jisilu): add timeline and question adapters for jisilu.cn#139yetingsky wants to merge 1 commit intojackwener:mainfrom
Conversation
Astro-Han
left a comment
There was a problem hiding this comment.
Nice addition for the jisilu community! A few things to address:
Code style — double quotes
The project's biome config requires single quotes. Both files use double quotes throughout, which will likely be caught by CI or pre-commit hooks.
question.ts — id should be positional
Per CONTRIBUTING.md, main target args (id, url, query) should use positional: true. opencli jisilu question 519605 is more natural than --id 519605.
question.ts — missing return value guard
return data on line 79 has no Array.isArray check. If evaluate returns null (page not found, JS error), the output formatter will crash. Other adapters use return Array.isArray(data) ? data : [].
timeline.ts — missing navigateBefore: false
With Strategy.COOKIE + domain, the framework auto-navigates to www.jisilu.cn before func runs, then func navigates again to /home/mine/#all — double navigation wasting 2-3s.
likes column — hardcoded to 0
Both post and replies always show likes: 0. If the data isn't available on the page, consider removing the column rather than showing misleading zeros.
Tests & docs
No E2E tests or documentation updates (README, docs/adapters/, SKILL.md). Per TESTING.md, question (PUBLIC) → browser-public.test.ts, timeline (COOKIE) → browser-auth.test.ts.
Summary
jisilu timelinecommand to fetch personal timeline from jisilu.cn (requires login)jisilu questioncommand to fetch post content and comments from jisilu.cnFeatures
timeline
/home/mine/#all--limitparameterquestion
--limitparameter to limit number of commentsUsage
Testing
Both commands have been tested successfully with various limit values.