mirror of
https://github.com/jxxghp/MoviePilot.git
synced 2026-11-20 10:56:26 +08:00
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>
26 lines
727 B
Python
26 lines
727 B
Python
"""兼容旧 ``app.db.user_oper`` 中混合的数据访问与认证依赖。"""
|
|
|
|
from app.api.deps import (
|
|
get_current_active_manage_user,
|
|
get_current_active_manage_user_async,
|
|
get_current_active_superuser,
|
|
get_current_active_superuser_async,
|
|
get_current_active_user,
|
|
get_current_active_user_async,
|
|
get_current_user,
|
|
get_current_user_async,
|
|
)
|
|
from app.db.oper.user import UserOper
|
|
|
|
__all__ = [
|
|
"UserOper",
|
|
"get_current_active_manage_user",
|
|
"get_current_active_manage_user_async",
|
|
"get_current_active_superuser",
|
|
"get_current_active_superuser_async",
|
|
"get_current_active_user",
|
|
"get_current_active_user_async",
|
|
"get_current_user",
|
|
"get_current_user_async",
|
|
]
|