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
But with the addition of py.typed in 3.5.2, mypy complains:
mwe.py:13: error: Argument 1 to "process_string" has incompatible type "Parameter"; expected "str" [arg-type]
Found 1 error in 1 file (checked 1 source file)
At runtime in the user code, the param member isn't an instance of Parameter; rather, it has been overwritten here with the parsed, normalized parameter value, which has the expected type.
Is there any guidance on writing type-checked code in 3.5.2? Or will type compliance be added later? Otherwise, could the addition of py.typed be reverted?
Thank you!
The text was updated successfully, but these errors were encountered:
The mypy type checker accepted the following code before 3.5.2:
But with the addition of
py.typed
in 3.5.2, mypy complains:At runtime in the user code, the
param
member isn't an instance ofParameter
; rather, it has been overwritten here with the parsed, normalized parameter value, which has the expected type.Is there any guidance on writing type-checked code in 3.5.2? Or will type compliance be added later? Otherwise, could the addition of
py.typed
be reverted?Thank you!
The text was updated successfully, but these errors were encountered: