fix(login): 避免登录预算配置锁阻塞恢复任务

This commit is contained in:
yml
2026-11-28 22:00:58 +08:00
parent 63e44a419f
commit 53626e4c2c
4 changed files with 4 additions and 9 deletions
+1 -1
View File
@@ -1,6 +1,6 @@
# 直播账号运营后台
斗鱼 / 虎牙账号运营 Web 平台:批量登录拿 Cookie、按工作台跑活动任务、应用宝点券充值。版本见 `pyproject.toml`(当前 0.4.15)。
斗鱼 / 虎牙账号运营 Web 平台:批量登录拿 Cookie、按工作台跑活动任务、应用宝点券充值。版本见 `pyproject.toml`(当前 0.4.16)。
## 能做什么
+1 -1
View File
@@ -1,6 +1,6 @@
[project]
name = "live-hub-py"
version = "0.4.15"
version = "0.4.16"
description = "直播账号运营 Web 后台"
readme = "README.md"
requires-python = ">=3.12,<3.13"
Generated
+1 -1
View File
@@ -381,7 +381,7 @@ wheels = [
[[package]]
name = "live-hub-py"
version = "0.4.15"
version = "0.4.16"
source = { editable = "." }
dependencies = [
{ name = "alembic" },
+1 -6
View File
@@ -204,12 +204,7 @@ def classify_login_category(
def _setting(db: Session) -> LoginQuotaSetting:
row = (
db.query(LoginQuotaSetting)
.filter(LoginQuotaSetting.id == 1)
.with_for_update()
.first()
)
row = db.query(LoginQuotaSetting).filter(LoginQuotaSetting.id == 1).first()
if row is None:
row = LoginQuotaSetting(id=1)
db.add(row)