Commit Graph

456 Commits

Author SHA1 Message Date
jxxghp
f7fe0c8fe0 chore(types): govern database backup application service 2026-10-16 16:29:45 +08:00
jxxghp
81dea8e2ef refactor(types): define server reporting payload mappings 2026-10-16 16:17:08 +08:00
jxxghp
ba9a7b074f refactor(types): preserve per-call agent task transaction results 2026-10-16 16:08:18 +08:00
jxxghp
fd22007ce4 refactor(types): align plugin configuration command contracts 2026-10-16 15:52:29 +08:00
jxxghp
8c59a89d57 fix(transfer): debounce monitored file success notifications (#7026) 2026-10-16 13:24:31 +08:00
jxxghp
11c4b0394a fix(events): preserve video metadata when replaying durable events (#7024) 2026-10-16 12:44:39 +08:00
jxxghp
7e24ce62c3 fix(plugin): restrict update badges to bound repositories 2026-10-16 12:29:20 +08:00
jxxghp
70aa163568 fix(search): reject punctuated English word fragments (#7019) 2026-10-16 12:28:37 +08:00
jxxghp
65e86f8f3d refactor(types): govern torrent cache recognition result types 2026-10-16 10:54:03 +08:00
jxxghp
4955b7b9ea fix: harden backend isolation and execution safety 2026-10-16 09:11:28 +08:00
jxxghp
0eb79ceee2 fix(storage): preserve shared category directories during media cleanup (#7012) 2026-10-16 00:33:47 +08:00
InfinityPacer
9181ad2b65 feat(community): serve community medals from the Wiki registry behind remote switches
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-15 22:28:58 +08:00
InfinityPacer
8249450014 chore(settings): regenerate system settings catalog
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-15 22:28:58 +08:00
jxxghp
ea60ed0fd6 feat(community): recognize GitHub contributions and honor levels 2026-10-15 12:11:36 +08:00
jxxghp
2c889a1735 fix(subscribe): 站点本地流控按限流窗口退避 (#6996) (#7001)
订阅分页搜索遇到站点本地流控(limit_interval/limit_count/limit_seconds)
拒绝时只按秒级 cooldown 反复重试,在整个限流窗口内持续触发风控。现在:

- 本地流控被拒时按站点配置窗口计算退避(访问间隔与计数窗口取最大值,
  并多留 1 秒越过窗口的严格比较边界);
- 同一退避写入站点预算冷却,窗口内其它订阅任务不会继续访问该站点;
- 本地流控没有发出请求,不计入连续失败与错误退避类别。
2026-10-15 09:14:13 +08:00
jxxghp
91b70ee2ce fix(wechatclawbot): 识别 item_list 媒体入站消息并修正 CDN 探测判定 (#7000)
* fix(wechatclawbot): 识别 item_list 媒体入站消息并修正 CDN 探测判定 (#6992)

iLink 下行媒体报文把附件放在 item_list 子项中,原解析存在三处缺口,
图片/语音/文件入站消息会被判为空消息丢弃:

- item_list 仅按数字 type 处理 1 文本/2 图片/5、6 文件,缺少 3 语音/
  4 文件/5 视频分派;改为按实际出现的子项键名分派,同时兼容历史
  type=5/6 文件报文。
- 附件引用只读取顶层 url/aeskey,识别不了 image_item.media.full_url /
  media.aes_key 等嵌套字段;统一按“顶层优先、media 子对象兜底”提取。
- 消息被解析为空时直接返回 None,日志只剩“未识别到有效消息”;补充
  渠道级诊断日志,输出 message_id 与截断后的原始报文。

另外把“微信 ClawBot 媒体 CDN”网络探测的 400 纳入成功状态码:该 CDN
对无参数裸请求固定返回 400,此前探测项恒定误报失败。

tests/test_wechatclawbot.py 整文件迁移为 pytest 原生,并新增 item_list
媒体解析、仅图片消息可入链、空消息诊断日志回归;nettest 契约测试补充
CDN 400 探测用例。复杂度与 mypy 低水位随债务下降同步固化。

* fix(wechatclawbot): 同步架构清单中的 mypy 债务数字 (#6992)
2026-10-15 09:02:59 +08:00
flippedyizheng
3484e6a82d fix(scheduler): skip CookieCloud schedule when credentials are missing (#6999)
定时同步仅在来源与凭据完整时注册,并在相关配置变更时重建任务;
手动同步入口保持不变。

Fixes #6995

Co-authored-by: jxxghp <jxxghp@gmail.com>
2026-10-15 07:27:22 +08:00
jxxghp
57b883d2bf feat(music): add global local cover control 2026-10-15 07:20:44 +08:00
jxxghp
72c8bff312 feat(music): preserve local covers and fall back after online scraping fails 2026-10-14 23:15:41 +08:00
jxxghp
c4cd6c8ac4 fix(download): confirm tracker forms and blacklist invalid torrents 2026-10-13 21:54:37 +08:00
jxxghp
8cbba9916e fix(subscribe): prefer complete packs for initial TV downloads 2026-10-13 21:16:22 +08:00
jxxghp
48cffca3a1 feat(transfer): aggregate successful notifications by batch (#6981) 2026-10-13 17:21:17 +08:00
jxxghp
98bd038623 fix(music): reconcile album completion and prevent duplicate downloads
Recover complete release coverage from successful local transfers and audio tags/CUE before subscription searches. Keep release-group and album boundaries, and reject completed torrent hashes before downloader submission.
2026-10-13 17:05:57 +08:00
JontyLee
a94dac60a9 fix(music): fall back to tags when cue index is broken for split albums (#6978) 2026-10-13 15:32:19 +08:00
jxxghp
edc719596d feat(update): prepare latest updates for a single restart 2026-10-13 12:50:01 +08:00
jxxghp
86c7fccfd5 feat(subscribe): persist business activity with scoped details 2026-10-12 23:43:01 +08:00
jxxghp
bd1e6eb899 fix(agent): separate public API queries from bound user operations 2026-10-12 07:30:35 +08:00
jxxghp
391f55df40 feat(subscribe): add isolated execution logs with authorized streaming (#6963) 2026-10-11 22:18:37 +08:00
jxxghp
453a3479aa fix(music): keep detached audio readable on ACL mounts (#6961) 2026-10-11 13:24:29 +08:00
jxxghp
0cbdbf9b1d fix(search): cap paging and stop unmatched IMDb sources 2026-10-11 07:46:38 +08:00
InfinityPacer
25aaf3a32b feat(plugin): add agent pet extension contract
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-11 04:08:15 +08:00
InfinityPacer
338687bee8 fix(download): treat blank save path as default directory
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-10 23:48:50 +08:00
jxxghp
dd90883c5d fix(torrent): respect tracker rate limits and quota cooldowns
Recognize explicit JSON rate limits before torrent parsing and short retries. Preserve per-call quota errors through download preparation so subscription cooldowns cover the tracker window.

Refs #6950
2026-10-10 23:34:35 +08:00
jxxghp
bb29451222 fix: isolate unhandled durable transfer failures 2026-10-10 12:17:07 +08:00
jxxghp
e9f0c693e2 fix(torrent): retry transient downloads and shorten empty-content cooldown 2026-10-10 00:05:22 +08:00
jxxghp
4caa1885ae Merge pull request #6928 from cwd0204/style/ruff-autofix 2026-10-09 18:11:43 +08:00
InfinityPacer
6034dcc880 fix(workflow): drop shared context on fork and legacy pickle context
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-09 13:56:35 +08:00
freeman
f3ad81b39e style: apply safe ruff auto-fixes and exempt startup late imports
Run `ruff check app tests scripts --fix` with the configured rule set
(E4/E7/E9/F/I): import sorting (I001), f-strings without placeholders
(F541), lambda/variable/unused-import cleanups that ruff marks safe.
Nine files whose only ruff debt sits next to pre-existing pylint
import-resolution errors (lazy exports, sys.path script imports) or
whose "unused" imports are reached through attribute access by tests are
left untouched so the changed-file pylint gate and the benchmark tests
stay green; their diagnostics remain in the baseline.

app/startup/lifecycle/__init__.py and app/main.py import business
modules after cache composition, import-path and stdio setup on purpose
(the source comments document the contract), so declare E402
per-file-ignores for them instead of adding per-line noqa.

Ruff ratchet watermark drops from 498 to 100; sync the baseline fixture
and the optimization checklist figure.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
2026-10-09 13:29:09 +08:00
jxxghp
233be41b49 Merge pull request #6925 from cwd0204/fix/login-throttle 2026-10-09 13:04:40 +08:00
freeman
2165475dd0 fix(security): throttle password login after repeated failures
The access-token endpoint accepted unlimited password attempts; the
only existing rate limiters are single-instance helpers for outbound
site requests. Add app/application/security/throttle.py, an in-memory
LoginThrottle keyed by (client address, normalized username) that locks
for 30s after five consecutive failures and doubles the lockout up to
15 minutes. The endpoint answers 429 with Retry-After while locked,
counts only real credential failures (an MFA challenge after a correct
password does not count), and clears the record on success.

X-Forwarded-For is deliberately not trusted because there is no
trusted-proxy setting; behind the bundled nginx all requests share one
address, so the key degrades to per-username throttling, which is the
dimension brute-force protection needs. Sync the dependency snapshot
and architecture metrics for the new module.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
2026-10-09 12:01:04 +08:00
jxxghp
54f2daba06 fix(subscribe): stop automatic searches and downloads when paused 2026-10-09 12:00:18 +08:00
jxxghp
70811b551e feat(music): optionally simplify written lyrics 2026-10-08 18:40:16 +08:00
jxxghp
32d37fa8b4 feat(music): preserve per-task CUE recognition policy 2026-10-08 08:51:01 +08:00
ChantXu64
e5e2558585 feat(search): 订阅补全逐页搜索、断点续搜与资源页手动分页 (#6907) 2026-10-07 14:40:55 +08:00
jxxghp
e51fd44964 fix(agent): resolve alternative QQ and Feishu user bindings
Keep strict binding lookup as the default and explicitly match alternative channel identifiers for the Agent API gateway. Reject ambiguous active-user matches and cover single-field bindings with database-backed tests.

Refs #6905
2026-10-07 09:16:33 +08:00
Freeman
4e9e868862 feat(download): accept configured directory names as save_path
validate_download_save_path keeps path-first semantics and falls back to an
exact match on the configured download directory name, returning that
directory's root URI so every download entry point can save by alias.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
2026-10-06 15:07:24 +08:00
JontyLee
5cc0375ec1 fix(audio): ignore stale CUE sheets whose referenced files are gone
Adopt a CUE only when at least one FILE reference resolves to a real
file in the audio directory. Legacy WAV-era cue sheets shipped inside
FLAC split-track releases previously blocked every track transfer with
"CUE 引用的文件名与当前音频不一致" (and broken-index cues did the same);
they are now ignored with an info log and organization falls back to
the files' own tags. Cross-directory references and cues that still
point at existing files keep the current strict behavior.

Refs: https://github.com/jxxghp/MoviePilot/issues/6888
2026-10-05 20:20:34 +08:00
jxxghp
84e3787b57 Merge pull request #6893 from MiCat-S/fix/nettest-tmdb-web-user-agent 2026-10-05 17:47:15 +08:00
jxxghp
fb652c74f4 fix(music): 支持关闭 CUE 识别整理分轨音频 2026-10-05 17:15:14 +08:00
LIN student
36e68b133c fix(nettest): TMDB 网站连通性测试使用程序自身 UA
网速连通性测试对所有目标统一发送浏览器 UA(NORMAL_USER_AGENT)。
www.themoviedb.org 对自称 Chrome、但 TLS 握手特征来自 Python 客户端的
请求返回 403 人机校验页(Just a moment...),因此网络正常时该项也固定
显示「错误码:403」。同一请求换成程序自身 UA(USER_AGENT)即返回 200;
TMDB API 两个目标不受影响。

tmdb_web 规则改为携带 USER_AGENT 请求头;未配置时沿用原有浏览器 UA。

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-05 16:52:41 +08:00