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

Pandas FutureWarning: Length 1 tuple will be returned #1356

Closed
R-Palazzo opened this issue Apr 4, 2023 · 0 comments · Fixed by #1374
Closed

Pandas FutureWarning: Length 1 tuple will be returned #1356

R-Palazzo opened this issue Apr 4, 2023 · 0 comments · Fixed by #1374
Labels
internal The issue doesn't change the API or functionality
Milestone

Comments

@R-Palazzo
Copy link
Contributor

Problem Description

Running the sdv/tests with pytests raised the following pandas warning:

FutureWarning: In a future version of pandas, a length 1 tuple will be returned when iterating over a groupby with a grouper equal to a list of length 1. Don't supply a list with a single grouper to avoid this warning.

Expected behavior

We want to modify the code to no longer get this warning.

Additional context

Here is given the code lines in sdv that raised the warning. Because this list may be incomplete, it would be nice to check after the correction that the warning is not in the warning summary of pytests.

Lines to be modified:

/sdv/constraints/base.py:502
/sdv/single_table/base.py:889
/sdv/sequential/par.py:138
/sdv/single_table/base.py:927
@R-Palazzo R-Palazzo added internal The issue doesn't change the API or functionality maintenance Tasks related to infrastructure & dependencies new Automatic label applied to new issues labels Apr 4, 2023
@npatki npatki changed the title Pandas warning 2 Pandas FutureWarning: Length 1 tuple will be returned Apr 4, 2023
@npatki npatki removed maintenance Tasks related to infrastructure & dependencies new Automatic label applied to new issues labels Apr 4, 2023
@amontanez24 amontanez24 added this to the 1.0.1 milestone Apr 20, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
internal The issue doesn't change the API or functionality
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants