File tree 4 files changed +6
-6
lines changed
4 files changed +6
-6
lines changed Original file line number Diff line number Diff line change @@ -6301,7 +6301,7 @@ def sort_values( # type: ignore[override]
6301
6301
else :
6302
6302
return result .__finalize__ (self , method = "sort_values" )
6303
6303
6304
- @deprecate_nonkeyword_arguments (version = "2.0" , allowed_args = ["self" ])
6304
+ @deprecate_nonkeyword_arguments (version = None , allowed_args = ["self" ])
6305
6305
def sort_index (
6306
6306
self ,
6307
6307
axis : Axis = 0 ,
Original file line number Diff line number Diff line change @@ -3435,7 +3435,7 @@ def sort_values(
3435
3435
else :
3436
3436
return result .__finalize__ (self , method = "sort_values" )
3437
3437
3438
- @deprecate_nonkeyword_arguments (version = "2.0" , allowed_args = ["self" ])
3438
+ @deprecate_nonkeyword_arguments (version = None , allowed_args = ["self" ])
3439
3439
def sort_index (
3440
3440
self ,
3441
3441
axis = 0 ,
Original file line number Diff line number Diff line change @@ -872,8 +872,8 @@ def test_sort_index_pos_args_deprecation(self):
872
872
# https://github.com/pandas-dev/pandas/issues/41485
873
873
df = DataFrame ({"a" : [1 , 2 , 3 ]})
874
874
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"
877
877
)
878
878
with tm .assert_produces_warning (FutureWarning , match = msg ):
879
879
df .sort_index (1 )
Original file line number Diff line number Diff line change @@ -325,8 +325,8 @@ def test_sort_index_pos_args_deprecation(self):
325
325
# https://github.com/pandas-dev/pandas/issues/41485
326
326
ser = Series ([1 , 2 , 3 ])
327
327
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"
330
330
)
331
331
with tm .assert_produces_warning (FutureWarning , match = msg ):
332
332
ser .sort_index (0 )
You can’t perform that action at this time.
0 commit comments