Skip to content

Commit c951d50

Browse files
committed
fixup post merge
1 parent 488c56d commit c951d50

File tree

4 files changed

+6
-6
lines changed

4 files changed

+6
-6
lines changed

pandas/core/frame.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -6301,7 +6301,7 @@ def sort_values( # type: ignore[override]
63016301
else:
63026302
return result.__finalize__(self, method="sort_values")
63036303

6304-
@deprecate_nonkeyword_arguments(version="2.0", allowed_args=["self"])
6304+
@deprecate_nonkeyword_arguments(version=None, allowed_args=["self"])
63056305
def sort_index(
63066306
self,
63076307
axis: Axis = 0,

pandas/core/series.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -3435,7 +3435,7 @@ def sort_values(
34353435
else:
34363436
return result.__finalize__(self, method="sort_values")
34373437

3438-
@deprecate_nonkeyword_arguments(version="2.0", allowed_args=["self"])
3438+
@deprecate_nonkeyword_arguments(version=None, allowed_args=["self"])
34393439
def sort_index(
34403440
self,
34413441
axis=0,

pandas/tests/frame/methods/test_sort_index.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -872,8 +872,8 @@ def test_sort_index_pos_args_deprecation(self):
872872
# https://github.com/pandas-dev/pandas/issues/41485
873873
df = DataFrame({"a": [1, 2, 3]})
874874
msg = (
875-
r"Starting with Pandas version 2\.0 all arguments of sort_index "
876-
r"except for the argument 'self' will be keyword-only"
875+
r"In a future version of pandas all arguments of DataFrame.sort_index "
876+
r"will be keyword-only"
877877
)
878878
with tm.assert_produces_warning(FutureWarning, match=msg):
879879
df.sort_index(1)

pandas/tests/series/methods/test_sort_index.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -325,8 +325,8 @@ def test_sort_index_pos_args_deprecation(self):
325325
# https://github.com/pandas-dev/pandas/issues/41485
326326
ser = Series([1, 2, 3])
327327
msg = (
328-
r"Starting with Pandas version 2\.0 all arguments of sort_index "
329-
r"except for the argument 'self' will be keyword-only"
328+
r"In a future version of pandas all arguments of Series.sort_index "
329+
r"will be keyword-only"
330330
)
331331
with tm.assert_produces_warning(FutureWarning, match=msg):
332332
ser.sort_index(0)

0 commit comments

Comments
 (0)