You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Typing of a couple of parameters is wrong. They are set to be str or Optional[str] only, when they can accept lists or tuples. Specifically it's the following functions:
To Reproduce
Simply run mypy with parameters being a tuple or list of strings.
Error
************.py: note: In function "merge":
************.py:165: error: Argument "revisions" to "merge" has incompatible type "List[str]"; expected "str" [arg-type]
config, revisions=revisions, message=message, branch_label=branch_label
^
************.py: note: In function "revision":
************.py:262: error: Argument "depends_on" to "revision" has incompatible type "Tuple[str]"; expected "Optional[str]" [arg-type]
depends_on=depends_on,
^
************.py: note: In function "stamp":
************.py:302: error: Argument "revision" to "stamp" has incompatible type "Tuple[str]"; expected "str" [arg-type]
Versions.
OS: MacOs
Python: 3.9.7
Alembic: 1.7.3
SQLAlchemy: 1.4.25
Database: not relevant
DBAPI: not relevant
Additional context
None
Have a nice day!
The text was updated successfully, but these errors were encountered:
Describe the bug
Typing of a couple of parameters is wrong. They are set to be str or Optional[str] only, when they can accept lists or tuples. Specifically it's the following functions:
alembic.command.revision
-depends_on
parameteralembic.command.stamp
-revisions
parameteralembic.command.merge
-revisions
parameterExpected behavior
The typing should reflect the implementation.
To Reproduce
Simply run mypy with parameters being a tuple or list of strings.
Error
Versions.
Additional context
None
Have a nice day!
The text was updated successfully, but these errors were encountered: