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

FutureWarning: The behavior of DataFrame concatenation with empty or all-NA entries is deprecated #125

Open
paulschreiber opened this issue Jun 24, 2024 · 0 comments
Assignees

Comments

@paulschreiber
Copy link
Member

Description

Fix the code causing this warning:

soil_id/tests/us/test_us.py::test_empty_rank
  /Users/paul/.dev/soil-id-algorithm/soil_id/utils.py:1012: FutureWarning: The behavior of DataFrame concatenation with 
empty or all-NA entries is deprecated. In a future version, this will no longer exclude empty or all-NA columns when 
determining the result dtypes. To retain the old behavior, exclude the relevant entries before the concat operation.
    site_vars = pd.concat([p_slope, mucompdata[["compname", "slope_r", "elev_r"]]], axis=0)

-- Docs: https://docs.pytest.org/en/stable/how-to/capture-warnings.html
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

No branches or pull requests

2 participants