Skip to content

Commit bca35ff

Browse files
authored
DEP: Enforce fname to path renaming (#49288)
1 parent 0d95478 commit bca35ff

File tree

2 files changed

+1
-3
lines changed

2 files changed

+1
-3
lines changed

doc/source/whatsnew/v2.0.0.rst

+1
Original file line numberDiff line numberDiff line change
@@ -229,6 +229,7 @@ Removal of prior version deprecations/changes
229229
- Enforced disallowing a string column label into ``times`` in :meth:`DataFrame.ewm` (:issue:`43265`)
230230
- Removed setting Categorical._codes directly (:issue:`41429`)
231231
- Enforced :meth:`Rolling.count` with ``min_periods=None`` to default to the size of the window (:issue:`31302`)
232+
- Renamed ``fname`` to ``path`` in :meth:`DataFrame.to_parquet`, :meth:`DataFrame.to_stata` and :meth:`DataFrame.to_feather` (:issue:`30338`)
232233
- Enforced the ``display.max_colwidth`` option to not accept negative integers (:issue:`31569`)
233234
- Removed the ``display.column_space`` option in favor of ``df.to_string(col_space=...)`` (:issue:`47280`)
234235
- Removed the deprecated method ``mad`` from pandas classes (:issue:`11787`)

pandas/core/frame.py

-3
Original file line numberDiff line numberDiff line change
@@ -2550,7 +2550,6 @@ def _from_arrays(
25502550
storage_options=_shared_docs["storage_options"],
25512551
compression_options=_shared_docs["compression_options"] % "path",
25522552
)
2553-
@deprecate_kwarg(old_arg_name="fname", new_arg_name="path")
25542553
def to_stata(
25552554
self,
25562555
path: FilePath | WriteBuffer[bytes],
@@ -2710,7 +2709,6 @@ def to_stata(
27102709
)
27112710
writer.write_file()
27122711

2713-
@deprecate_kwarg(old_arg_name="fname", new_arg_name="path")
27142712
def to_feather(self, path: FilePath | WriteBuffer[bytes], **kwargs) -> None:
27152713
"""
27162714
Write a DataFrame to the binary Feather format.
@@ -2820,7 +2818,6 @@ def to_parquet(
28202818
...
28212819

28222820
@doc(storage_options=_shared_docs["storage_options"])
2823-
@deprecate_kwarg(old_arg_name="fname", new_arg_name="path")
28242821
def to_parquet(
28252822
self,
28262823
path: FilePath | WriteBuffer[bytes] | None = None,

0 commit comments

Comments
 (0)