Skip to content

Commit

Permalink
[SPARK-35811][PYTHON][FOLLOWUP] Deprecate DataFrame.to_spark_io
Browse files Browse the repository at this point in the history
### What changes were proposed in this pull request?

This PR is followup for #32964, to improve the warning message.

### Why are the changes needed?

To improve the warning message.

### Does this PR introduce _any_ user-facing change?

The warning is changed from "Deprecated in 3.2, Use `spark.to_spark_io` instead." to "Deprecated in 3.2, Use `DataFrame.spark.to_spark_io` instead."

### How was this patch tested?

Manually run `dev/lint-python`

Closes #33631 from itholic/SPARK-35811-followup.

Authored-by: itholic <haejoon.lee@databricks.com>
Signed-off-by: Hyukjin Kwon <gurwls223@apache.org>
  • Loading branch information
itholic authored and HyukjinKwon committed Aug 4, 2021
1 parent de62b5a commit 3d72c20
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion python/pyspark/pandas/frame.py
Original file line number Diff line number Diff line change
Expand Up @@ -4808,7 +4808,7 @@ def to_spark_io(
.. deprecated:: 3.2.0
Use :func:`DataFrame.spark.to_spark_io` instead.
"""
warnings.warn("Deprecated in 3.2, Use spark.to_spark_io instead.", FutureWarning)
warnings.warn("Deprecated in 3.2, Use DataFrame.spark.to_spark_io instead.", FutureWarning)
return self.spark.to_spark_io(path, format, mode, partition_cols, index_col, **options)

to_spark_io.__doc__ = SparkFrameMethods.to_spark_io.__doc__
Expand Down

0 comments on commit 3d72c20

Please sign in to comment.