feat: はなみすきーの notes/hanamisearch-v1 に対応 - #50
Merged
Conversation
はなみすきー (hanamisskey/misskey) はロールポリシー canSearchNotes が false で本家 notes/search が常に UNAVAILABLE を返すため、独自エンドポイント notes/hanamisearch-v1 を叩く search_notes_hanami() を追加する。 このエンドポイントは sinceDate/untilDate を受け付けないが、サーバー側で sinceId/untilId を idService.parse() で createdAt に戻して比較しているため、 日付を Misskey ID の時刻部 (base36 8 桁) に変換して渡すことで代替する。 Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
|
Important Review skippedAuto reviews are disabled on base/target branches other than the default branch. Please check the settings in the CodeRabbit UI or the ⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Plus Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
Comment |
This was referenced Aug 2, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
なぜ
はなみすきー (misskey.flowers) はロールポリシー
canSearchNotes: falseで本家notes/searchを無効化しており、search_notes()が常にUNAVAILABLEを返す。代わりにcanSearchWithHanamiSearchV1: trueでnotes/hanamisearch-v1が全ログインユーザーに開放されている。なにを
MisskeyClient::search_notes_hanami()を追加。notes/hanamisearch-v1sinceDate/untilDateは非対応なので、Misskey ID の時刻部 (2000-01-01 起点 ms の base36 8 桁) に変換してsinceId/untilIdに載せる。サーバー側はidService.parse()で createdAt に戻して比較しているのでこれで日付フィルタとして機能するsinceId/untilIdが明示されていればそちらを優先するエンコードは misskey.flowers の実 ID (
apfldnaym0v100e3/2026-08-02T16:41:40.666Z) で検証済み。呼び出し側の出し分けは NoteDeck 側 (notedeck-dev/notedeck#916 / #917) のアダプター層で行う。
テスト
misskey_id_at_encodes_time_part— 時刻部エンコードsearch_notes_hanami_uses_hanamisearch_endpoint— エンドポイントと日付→ID 変換search_notes_hanami_prefers_explicit_pagination_ids— untilId 優先🤖 Generated with Claude Code