equinor / xtgeo

XTGeo Python class library for subsurface Surfaces, Cubes, Wells, Grids, Points, etc
https://xtgeo.readthedocs.io/en/latest/
GNU Lesser General Public License v3.0
110 stars 56 forks source link

Ensure all deprecations are consistent #1082

Closed mferrera closed 9 months ago

mferrera commented 9 months ago

This adds some deprecations that were forgotten and tries to cohere on consistent ones (e.g. preferring get_dataframe and set_dataframe over the dataframe getter setter property)

Resolves #1080

codecov-commenter commented 9 months ago

Codecov Report

Attention: 2 lines in your changes are missing coverage. Please review.

Comparison is base (56d76c3) 80.09% compared to head (497d69e) 80.11%.

Files Patch % Lines
src/xtgeo/xyz/points.py 83.33% 1 Missing :warning:
src/xtgeo/xyz/polygons.py 83.33% 1 Missing :warning:
Additional details and impacted files ```diff @@ Coverage Diff @@ ## main #1082 +/- ## ========================================== + Coverage 80.09% 80.11% +0.01% ========================================== Files 94 94 Lines 13426 13445 +19 Branches 2195 2195 ========================================== + Hits 10754 10771 +17 - Misses 1946 1948 +2 Partials 726 726 ```

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.

mferrera commented 9 months ago

My thought is that leaving it as a visible DeprecationNotice is okay. If this is a widely used feature then the longer that users are aware of it the better. Adapting to this particularly deprecation is pretty straight forward as well. My guess is that it will be well over a year before we hit xtgeo 5.0 at any rate.

mferrera commented 9 months ago

Updated the relevant dataframe properties to PendingDeprecationWarning