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
The above minimal example raises what appears to be a false type error on the last line due to passing columns=col_map:
Argument "columns" to "rename" of "DataFrame" has incompatible type "Dict[str, str]"; expected "Union[Mapping[Optional[Hashable], Any], Callable[[Optional[Hashable]], Optional[Hashable]], None]"mypy(error)
If instead I pass the dictionary as a literal value, the error disappears:
df.rename(columns={"a": "b"}) # all is well here
The text was updated successfully, but these errors were encountered:
The above minimal example raises what appears to be a false type error on the last line due to passing
columns=col_map
:If instead I pass the dictionary as a literal value, the error disappears:
The text was updated successfully, but these errors were encountered: