fix(monitor): 超级编导密码错了就别再自动重试,免得锁号
Deploy VitePress site to Pages / build (push) Canceled after 0s
Deploy VitePress site to Pages / Deploy (push) Canceled after 0s

超级编导对密码尝试有次数限制(实测提示今日剩余 4 次)。自动追加失败后每
30 分钟重试一次,密码错的话当天就能把账号锁掉。1002/10006/4026 这类凭据
错误改成 30 天后再试;设置页保存新凭据会把调度钟拨回现在,不会卡住。
This commit is contained in:
2026-10-25 11:10:45 +08:00
parent b05491e9de
commit cd2a276630
3 changed files with 34 additions and 2 deletions
+3 -2
View File
@@ -240,10 +240,11 @@ class MonitorScheduler:
result = await superdir.sync_task(session, task)
except Exception as exc:
# 失败**不推** last_at:接口挂了一小时,恢复后这一小时的作品还在
# 查询窗口里。只把调度钟往后挪一段较短的时间再试。
# 查询窗口里。只把调度钟往后挪。挪多久看错误类型 —— 账号密码错了
# 就几乎等于「等人来修」,继续每 30 分钟试一次会把号锁掉。
task.superdir_auto_last_error = str(exc)[:500]
task.superdir_auto_next_at = (
get_current_timestamp() + superdir.SYNC_FAILURE_RETRY_MS
get_current_timestamp() + superdir.retry_delay_ms(exc)
)
print(
f"[monitor.scheduler] 超级编导自动追加失败 task={task_id}: {exc}"