jxxghp
44df516565
refactor(types): specify workflow model query and transition results
2026-10-16 20:11:58 +08:00
jxxghp
a2bf0db215
fix(types): acknowledge missing workflow lookup results
2026-10-16 20:11:21 +08:00
jxxghp
5198cb0911
refactor(types): declare system config transaction callbacks
2026-10-16 20:09:31 +08:00
jxxghp
cd1a714421
refactor(types): specify subscription history query contracts
2026-10-16 20:08:35 +08:00
jxxghp
1703a11783
refactor(types): declare user lookup and mutation results
2026-10-16 20:07:32 +08:00
jxxghp
2846ed6b21
refactor(types): specify agent task statements and query results
2026-10-16 20:06:27 +08:00
jxxghp
fea8bd1bf8
refactor(types): specify persisted message field mapping
2026-10-16 20:05:25 +08:00
jxxghp
a3050387ae
refactor(types): declare queried agent task run records
2026-10-16 19:57:31 +08:00
jxxghp
64147fb669
refactor(types): declare queried agent chat records
2026-10-16 19:57:31 +08:00
jxxghp
c62d28e540
refactor(types): declare site model query results
2026-10-16 19:57:31 +08:00
jxxghp
8f2f4df9e1
refactor(types): declare media server model query results
2026-10-16 19:57:31 +08:00
jxxghp
810141f13d
refactor(types): declare passkey model query and mutation results
2026-10-16 19:57:10 +08:00
jxxghp
5477dbea93
refactor(types): declare queried download failure records
2026-10-16 19:36:28 +08:00
jxxghp
458f44da68
refactor(types): declare site user snapshot query results
2026-10-16 19:35:10 +08:00
jxxghp
e78e018921
refactor(types): declare plugin data model query results
2026-10-16 19:33:28 +08:00
jxxghp
3ce0c22af9
refactor(types): declare site statistics query results
2026-10-16 19:31:40 +08:00
jxxghp
ee1f417d4e
refactor(types): declare user configuration query results
2026-10-16 19:15:35 +08:00
jxxghp
a85cab1cce
refactor(types): declare optional site icon query results
2026-10-16 19:14:10 +08:00
jxxghp
eda541461d
refactor(types): declare plugin data write completion
2026-10-16 19:12:34 +08:00
jxxghp
4955b7b9ea
fix: harden backend isolation and execution safety
2026-10-16 09:11:28 +08:00
jxxghp
2c889a1735
fix(subscribe): 站点本地流控按限流窗口退避 ( #6996 ) ( #7001 )
...
订阅分页搜索遇到站点本地流控(limit_interval/limit_count/limit_seconds)
拒绝时只按秒级 cooldown 反复重试,在整个限流窗口内持续触发风控。现在:
- 本地流控被拒时按站点配置窗口计算退避(访问间隔与计数窗口取最大值,
并多留 1 秒越过窗口的严格比较边界);
- 同一退避写入站点预算冷却,窗口内其它订阅任务不会继续访问该站点;
- 本地流控没有发出请求,不计入连续失败与错误退避类别。
2026-10-15 09:14:13 +08:00
flippedyizheng
19f9098d68
fix(mediaserver): require unambiguous title-year match for cross-source fallback ( #6998 )
2026-10-15 07:15:06 +08:00
jxxghp
b82bbcb420
fix(webhook)!: guard unknown movie paths in transfer history
...
Recover Jellyfin deletion paths from webhook payloads or bounded server-scoped caches. Avoid querying deleted items and preserve TV season/series lookup behavior.
BREAKING CHANGE: Movie and unspecified-type history queries without a destination now return no records unless match_all_versions=True is explicitly requested.
Refs #6988
2026-10-13 23:48:10 +08:00
jxxghp
435703573e
fix(transfer): persist provider checkpoint planning time
...
Write planned_at atomically for provider_pending checkpoints and refresh it when host planning takes over. Cover real admission-to-execution persistence and distinguish incomplete plan fields from inconsistent execution checkpoint fields.
Refs #6973
2026-10-13 07:13:42 +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
bb29451222
fix: isolate unhandled durable transfer failures
2026-10-10 12:17:07 +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
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
jxxghp
3726ca078a
fix(mediaserver): isolate cached item ids by server ( #6850 )
2026-10-01 17:07:23 +08:00
jxxghp
47d51c3630
feat(agent): align history recall with Hermes SQLite FTS5
2026-09-30 16:28:39 +08:00
jxxghp
4a2ef75706
fix(music): retry transient recognition before freezing file operations
2026-09-30 06:36:04 +08:00
jxxghp
b4175a4f88
fix(image): cache site allowlist and include custom image hosts
2026-09-30 01:09:32 +08:00
moviepilot-codex[bot]
9df35e7b83
fix: 修复配置快照、依赖同步和 Agent 上限
2026-09-21 04:26:48 +08:00
jxxghp
67ae166a54
fix(servarr): restore subscription repository async contract
2026-09-18 22:13:33 +08:00
jxxghp
4e9a64c0f0
refactor(application): 按模块子目录统一文件命名
2026-09-15 23:57:06 +08:00
jxxghp
880cef2c88
fix(config): 使用公共日志模块记录配置恢复
2026-09-15 11:43:12 +08:00
jxxghp
f483e5fe14
fix(config): 修复非法系统配置阻断启动 ( #6702 )
2026-09-15 11:16:29 +08:00
Aqr-K
61aa3cd649
refactor(sdk): 插件契约基类迁入 SDK 并由 Compat 承接旧包根符号 ( #6701 )
2026-09-15 07:01:00 +08:00
jxxghp
6a165a72aa
fix(mediaserver): satisfy type ratchet
2026-09-15 00:28:19 +08:00
jxxghp
c587ff07f7
fix(mediaserver): support cross-source library status
2026-09-15 00:17:20 +08:00
jxxghp
ebddeee23b
feat(subscribe): accumulate music album track progress
2026-09-14 19:35:04 +08:00
Aqr-K
5e232ca14d
fix(plugin): 安装记录大小写不敏感查询、游标物化,site 端点改从 Application 取 ( #6682 )
...
* fix(plugin): 安装 journal 按大小写不敏感列出事务记录
create 用 func.lower 判定同一物理插件并据此拒绝重复占位,list 却还是等值过滤。
判据分叉后,恢复流程查不到那条被 create 认定为未收尾的 journal,会认为没有待恢复
事务,而新事务又永远被同一行挡住。list 改用与 create 相同的 func.lower 判据。
* fix(plugin): 批量读插件身份时在事务内物化游标
list_by_plugin_ids 无会话调用时由组合根另开短事务,会话在 lambda 返回后立即关闭,
外层再 list() 消费惰性游标会撞上 "identity map is no longer valid",一行都读不到。
补上 .all(),让行在事务内取完。
* refactor(api): site 端点从 Application 取插件路由刷新
register_plugin_api 的唯一拥有者是 app.application.plugin.routes,
dependencies/plugin.py、scheduler/reconcile.py 与 initializers/plugins.py 都已从那里
取用,只剩 site 端点还在向 plugin 端点横向借。改为同一来源,并加门禁锁住这条判据。
依赖基线相应下降一条边(8650 -> 8649:site 不再到达 app.api.endpoints 与
app.api.endpoints.plugin,改为到达 app.application.plugin.routes),mypy 低水位同步
下降一条 attr-defined,两处文档数字随之更新。
---------
Co-authored-by: jxxghp <jxxghp@gmail.com >
2026-09-14 07:18:50 +08:00
Aqr-K
6ea1cc9433
fix(plugin): 插件降级重装时拒绝迁移树不认识的库 revision ( #6681 )
2026-09-14 07:01:32 +08:00
Aqr-K
5fd04505c1
feat(plugin): 分身彻底清理,并按包含性校验收口插件数据目录解析 ( #6671 )
2026-09-13 21:05:04 +08:00
Aqr-K
d44480d739
Merge pull request #6666 from Aqr-K/feat/plugin-instance-target-enablement
...
feat(plugin): 插件实例默认调用目标与启停,未指定实例时不再兜底取第一个
2026-09-13 16:37:27 +08:00
jxxghp
c60949ffff
Merge branch 'v3' into feat/plugin-instance-config-logging
2026-09-13 14:30:42 +08:00
Aqr-K
3d594ecee3
refactor(plugin): 插件配置改走独立通道,SystemConfig 不再按键值分支
...
插件配置此前借用 systemconfig 的 plugin.<实例ID> 单键,为了换表又在
SystemConfigOper 的 set/delete/load_snapshot 里按该前缀开分支。这是反向依赖:
一个对所有键一视同仁的通用键值存储被迫知道「插件」这个概念,读写路径依键值而
异,「这个键落在哪张表」只有读代码才说得清;规范方法按值加特例,也让此后任何新
键都要先确认自己会不会被拦截。
本次把插件配置整条链拆出,形状与本分支日志等级那条链一致:
- SystemConfigOper 整体回退到官方实现,与 f70d7c141 逐字节相同,对所有键一视同仁。
- 配置端口改按实例 ID 寻址:PluginStorage 新增 read_config / write_config /
async_write_config / delete_config,PluginConfigStore 去掉 key_prefix 与 _key,
不再有任何字符串键经过;plugin_exists 存在性规则、空键过滤与 force 语义不变。
- PluginInstanceOper 补齐读取与异步写入原语 get_config_data /
async_save_config_data,同步与异步共用同一份落库决策,避免两条路径对「值未变化
不写」和「建行用哪个源插件」各自分叉。
- _PluginBase 的 get_config / update_config 直连 PluginInstanceOper,方法名、签名、
返回与 docstring 不变;self.systemconfig 保留,插件读 SystemConfigKey 枚举值仍
然合法,插件公开面没有扩大。
插件直接用 SystemConfig 存取自身配置不予支持。它本就不是封装过的插件配置通道,
为它设计兼容或加守卫拦截,等于再把「插件」塞回通用存储里——那正是本次要拆掉的东
西。拆开后 plugin.<ID> 只是一个与插件无关的普通 systemconfig 键:迁移已经把旧的
plugin.* 行搬进插件实例表,读它拿到 None,写它会新增一条谁也不读的 systemconfig
记录,插件配置通道既不读也不写它,两边不会再有任何交叉。
代价是读取从内存快照变成一次按实例 ID 的主键查询。调用点都不在热路径上:宿主侧
只有插件启动/重载、配置表单接口与分身创建三处,插件侧 get_config() 惯例在
init_plugin 里取一次。写入侧没有变化,本来就是一次事务。
回归防线:新增用例断言 SystemConfigOper 对 plugin. 前缀没有任何特殊行为——写进去
就是一行普通 systemconfig 记录,读出来就是刚写的值,不会被路由到插件实例表。
兼容层零改动,三个 alembic 迁移一行未改。
2026-09-13 01:41:57 -04:00
jxxghp
8072b7d78f
Refactor application architecture and compatibility boundaries
2026-09-13 12:53:00 +08:00