Skip to content

Commit

Permalink
fix: always cast series to bool dtype
Browse files Browse the repository at this point in the history
Signed-off-by: karlma821 <[email protected]>
  • Loading branch information
karlma821 committed Nov 16, 2023
1 parent af0e5c0 commit 1b97860
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion pandera/engines/pandas_engine.py
Original file line number Diff line number Diff line change
Expand Up @@ -718,7 +718,7 @@ def check(
)
else:
is_python_string = data_container.map(lambda x: isinstance(x, str)) # type: ignore[operator]
return is_python_string | data_container.isna()
return is_python_string.astype(bool) | data_container.isna()


Engine.register_dtype(
Expand Down

0 comments on commit 1b97860

Please sign in to comment.