-
-
Notifications
You must be signed in to change notification settings - Fork 143
BUG: columns
on existing DataFrame
does not accept "List[str]"
#73
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Labels
mypy bug
Requires mypy to fix a bug
Comments
This is a bug in Here's a simple example: from typing import Union
class Foobar:
def __init__(self, x: Union[int, str]):
self._x = self.makestr(x)
def makestr(self, x: Union[int, str]) -> str:
if isinstance(x, int):
return str(x)
elif isinstance(x, str):
return x
else:
raise Exception("invalid type")
@property
def x(self) -> str:
return self._x
@x.setter
def x(self, x: Union[int, str]) -> None:
self._x = self.makestr(x)
fb = Foobar("abc")
fb.x = 3 mypy will then report:
|
|
closed via #1236 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
The text was updated successfully, but these errors were encountered: