From d10b62f54e6b9dd0613c0412b924c1b346ec1611 Mon Sep 17 00:00:00 2001 From: Federico Caselli Date: Mon, 17 Oct 2022 22:02:13 +0200 Subject: Improve typings of execution options Fixes: #8605 Change-Id: I4aec83b9f321462427c3f4ac941c3b272255c088 --- lib/sqlalchemy/sql/selectable.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'lib/sqlalchemy/sql/selectable.py') diff --git a/lib/sqlalchemy/sql/selectable.py b/lib/sqlalchemy/sql/selectable.py index 7c73255d7..9de015774 100644 --- a/lib/sqlalchemy/sql/selectable.py +++ b/lib/sqlalchemy/sql/selectable.py @@ -105,7 +105,6 @@ and_ = BooleanClauseList.and_ _T = TypeVar("_T", bound=Any) if TYPE_CHECKING: - import sqlalchemy from ._typing import _ColumnExpressionArgument from ._typing import _FromClauseArgument from ._typing import _JoinTargetArgument @@ -130,6 +129,7 @@ if TYPE_CHECKING: from .cache_key import _CacheKeyTraversalType from .compiler import SQLCompiler from .dml import Delete + from .dml import Insert from .dml import Update from .elements import KeyedColumnElement from .elements import Label @@ -2997,7 +2997,7 @@ class TableClause(roles.DMLTableRole, Immutable, NamedFromClause): c.table = self @util.preload_module("sqlalchemy.sql.dml") - def insert(self) -> sqlalchemy.sql.expression.Insert: + def insert(self) -> Insert: """Generate an :func:`_expression.insert` construct against this :class:`_expression.TableClause`. -- cgit v1.2.1