Skip to content

Fix DataFrame.sort_index future warning#1036

Merged
dwhswenson merged 2 commits into
openpathsampling:masterfrom
sroet:fix_future_warning
Jul 20, 2021
Merged

Fix DataFrame.sort_index future warning#1036
dwhswenson merged 2 commits into
openpathsampling:masterfrom
sroet:fix_future_warning

Conversation

@sroet

@sroet sroet commented Jul 19, 2021

Copy link
Copy Markdown
Member

The test suite gave the following future warning:

openpathsampling/tests/test_lookup_function.py::TestVoxelLookupFunction::test_df_2d
  /home/sroet/github_files/openpathsampling/openpathsampling/numerics/lookup_function.py:268: FutureWarning: In a future version of pandas all arguments of DataFrame.sort_index will be keyword-only
    df = df.sort_index(0).sort_index(1)

066f87a implements the fix for that (make the arguments keyword based instead of location based).
90c75cf solves the pep8 complaints my coding environment was noticing

@codecov

codecov Bot commented Jul 19, 2021

Copy link
Copy Markdown

Codecov Report

Merging #1036 (90c75cf) into master (e8b091c) will decrease coverage by 0.00%.
The diff coverage is 100.00%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #1036      +/-   ##
==========================================
- Coverage   81.55%   81.54%   -0.01%     
==========================================
  Files         140      140              
  Lines       15400    15399       -1     
==========================================
- Hits        12559    12557       -2     
- Misses       2841     2842       +1     
Impacted Files Coverage Δ
openpathsampling/numerics/lookup_function.py 91.04% <100.00%> (-0.07%) ⬇️
openpathsampling/netcdfplus/cache.py 63.72% <0.00%> (-0.33%) ⬇️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update e8b091c...90c75cf. Read the comment docs.

@dwhswenson dwhswenson left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM. Will merge!

@dwhswenson dwhswenson merged commit d46e028 into openpathsampling:master Jul 20, 2021
@sroet sroet deleted the fix_future_warning branch July 21, 2021 08:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants