diff options
| author | Mike Bayer <mike_mp@zzzcomputing.com> | 2022-03-08 17:14:41 -0500 |
|---|---|---|
| committer | Mike Bayer <mike_mp@zzzcomputing.com> | 2022-03-13 15:29:20 -0400 |
| commit | 769fa67d842035dd852ab8b6a26ea3f110a51131 (patch) | |
| tree | 5c121caca336071091c6f5ea4c54743c92d6458a /lib/sqlalchemy/sql/dml.py | |
| parent | 77fc8216a74e6b2d0efc6591c6c735687bd10002 (diff) | |
| download | sqlalchemy-769fa67d842035dd852ab8b6a26ea3f110a51131.tar.gz | |
pep-484: sqlalchemy.sql pass one
sqlalchemy.sql will require many passes to get all
modules even gradually typed. Will have to pick and
choose what modules can be strictly typed vs. which
can be gradual.
in this patch, emphasis is on visitors.py, cache_key.py,
annotations.py for strict typing, compiler.py is on gradual
typing but has much more structure, in particular where it
connects with the outside world.
The work within compiler.py also reached back out to
engine/cursor.py , default.py quite a bit.
References: #6810
Change-Id: I6e8a29f6013fd216e43d45091bc193f8be0368fd
Diffstat (limited to 'lib/sqlalchemy/sql/dml.py')
| -rw-r--r-- | lib/sqlalchemy/sql/dml.py | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/lib/sqlalchemy/sql/dml.py b/lib/sqlalchemy/sql/dml.py index 5aded307b..96e90b0ea 100644 --- a/lib/sqlalchemy/sql/dml.py +++ b/lib/sqlalchemy/sql/dml.py @@ -13,6 +13,10 @@ from __future__ import annotations import collections.abc as collections_abc import typing +from typing import Any +from typing import List +from typing import MutableMapping +from typing import Optional from . import coercions from . import roles @@ -40,8 +44,8 @@ from .. import util class DMLState(CompileState): _no_parameters = True - _dict_parameters = None - _multi_parameters = None + _dict_parameters: Optional[MutableMapping[str, Any]] = None + _multi_parameters: Optional[List[MutableMapping[str, Any]]] = None _ordered_values = None _parameter_ordering = None _has_multi_parameters = False |
