From 05df51b749ee985bfbea7da2e91ecbd4e066d597 Mon Sep 17 00:00:00 2001 From: Bryan Van Deusen Date: Mon, 13 Jul 2026 21:49:30 -0400 Subject: [PATCH] fix(ml): drop unnecessary quotes on MLSettings.load annotations (UP037) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Python 3.14 evaluates annotations lazily, so the self-referential return type needs no forward-ref quotes — matches ImportSettings.load. Fixes the ruff lint lane on the DRY-pass push. Co-Authored-By: Claude Opus 4.8 (1M context) Claude-Session: https://claude.ai/code/session_01NsmJSQxnNxGgtM5Yz4GAqi --- backend/app/models/ml_settings.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/backend/app/models/ml_settings.py b/backend/app/models/ml_settings.py index 44aa4f1..72da17b 100644 --- a/backend/app/models/ml_settings.py +++ b/backend/app/models/ml_settings.py @@ -215,12 +215,12 @@ class MLSettings(Base): ) @classmethod - async def load(cls, session) -> "MLSettings": + async def load(cls, session) -> MLSettings: """The singleton settings row (id=1), via an async session. Mirrors ImportSettings.load — the shared singleton-loader pattern.""" return (await session.execute(select(cls).where(cls.id == 1))).scalar_one() @classmethod - def load_sync(cls, session) -> "MLSettings": + def load_sync(cls, session) -> MLSettings: """The singleton settings row (id=1), via a sync session.""" return session.execute(select(cls).where(cls.id == 1)).scalar_one()