fix: 修复 Telegram 翻页有时失效的多个 Bug#2
Merged
Merged
Conversation
- search.py: build_result() 不再猜测 message_id (+1),改为直接 使用 msg.message_id(真实回复消息 ID),解决缓存键不匹配导致 翻页静默失败的根本原因;缓存未命中时弹出提示而非静默返回 - torrent_search.py: 引入 KEYWORD_CACHE,callback_data 不再拼接 keyword 字符串,防止中文关键词超过 Telegram 64 字节限制导致 按钮点击无响应;RESULT_INDEXER 改为精准清理当前 cmid 条目, 不再全局 clear,避免并发搜索互相覆盖结果 - tmdb_search.py: 缓存键由 chat_id 改为 chat_id|message_id, RESULT_TMDB 同步更新键格式,解决同一 chat 多次搜索时 旧消息翻页失效及搜索结果互相覆盖的问题 https://claude.ai/code/session_01HNCfZLiNXHZcchtifn6b5T
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.
search.py: build_result() 不再猜测 message_id (+1),改为直接 使用 msg.message_id(真实回复消息 ID),解决缓存键不匹配导致 翻页静默失败的根本原因;缓存未命中时弹出提示而非静默返回
torrent_search.py: 引入 KEYWORD_CACHE,callback_data 不再拼接 keyword 字符串,防止中文关键词超过 Telegram 64 字节限制导致 按钮点击无响应;RESULT_INDEXER 改为精准清理当前 cmid 条目, 不再全局 clear,避免并发搜索互相覆盖结果
tmdb_search.py: 缓存键由 chat_id 改为 chat_id|message_id, RESULT_TMDB 同步更新键格式,解决同一 chat 多次搜索时 旧消息翻页失效及搜索结果互相覆盖的问题
https://claude.ai/code/session_01HNCfZLiNXHZcchtifn6b5T