Skip to content

Commit bec9763

Browse files
committed
Document conflicting MyPy and pyright results
1 parent f649e13 commit bec9763

File tree

1 file changed

+8
-2
lines changed

1 file changed

+8
-2
lines changed

tests/test_pandas.py

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -180,7 +180,10 @@ def test_isna() -> None:
180180
if not pd.notna(nullable2):
181181
# TODO: This is the true type (see comments above on the limitations of TypeGuard)
182182
# check(assert_type(nullable2, None), type(None))
183-
assert_type(nullable2, Union[int, NaTType, NAType, None])
183+
assert_type(nullable2, Union[int, None]) # TODO: MyPy result
184+
assert_type(
185+
nullable2, Union[int, NaTType, NAType, None]
186+
) # TODO: Pyright result
184187

185188
nullable3 = random.choice([True, None, pd.NA])
186189
if pd.notna(nullable3):
@@ -196,7 +199,10 @@ def test_isna() -> None:
196199
if not pd.notna(nullable3):
197200
# TODO: This is the true type (see comments above on the limitations of TypeGuard)
198201
# assert_type(nullable3, Union[NAType, None])
199-
assert_type(nullable3, Union[bool, NaTType, NAType, None])
202+
assert_type(nullable3, Union[bool, NAType, None]) # TODO: Mypy result
203+
assert_type(
204+
nullable3, Union[bool, NaTType, NAType, None]
205+
) # TODO: Pyright result
200206

201207

202208
# GH 55

0 commit comments

Comments
 (0)