Skip to content
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

fix: pandas df truthiness #782

Merged
merged 1 commit into from
Oct 25, 2023
Merged

fix: pandas df truthiness #782

merged 1 commit into from
Oct 25, 2023

Conversation

elboy3
Copy link
Contributor

@elboy3 elboy3 commented Oct 25, 2023

>>> bool(dataset)
---------------------------------------------------------------------------
ValueError                                Traceback (most recent call last)
[<ipython-input-9-c57750f91409>](https://localhost:8080/#) in <cell line: 1>()
----> 1 bool(dataset)

[/usr/local/lib/python3.10/dist-packages/pandas/core/generic.py](https://localhost:8080/#) in __nonzero__(self)
   1525     @final
   1526     def __nonzero__(self) -> NoReturn:
-> 1527         raise ValueError(
   1528             f"The truth value of a {type(self).__name__} is ambiguous. "
   1529             "Use a.empty, a.bool(), a.item(), a.any() or a.all()."

ValueError: The truth value of a DataFrame is ambiguous. Use a.empty, a.bool(), a.item(), a.any() or a.all().

@elboy3 elboy3 requested review from dcaustin33 and a team as code owners October 25, 2023 16:29
@elboy3 elboy3 enabled auto-merge (squash) October 25, 2023 16:31
@elboy3 elboy3 merged commit 50089ef into main Oct 25, 2023
@elboy3 elboy3 deleted the fix/pandas-df-truthiness branch October 25, 2023 16:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants