[SPARK-39861][PYTHON][DOCS] Deprecate Python 3.7 Support#37279
[SPARK-39861][PYTHON][DOCS] Deprecate Python 3.7 Support#37279dongjoon-hyun wants to merge 1 commit intoapache:masterfrom dongjoon-hyun:SPARK-39861
Python 3.7 Support#37279Conversation
|
cc @HyukjinKwon , @ueshin , @zero323 , @xinrong-meng , @itholic |
Python 3.7
Python 3.7Python 3.7 Support
|
cc @viirya , @huaxingao , @sunchao , too |
|
But it is better to open this for a while for others to take a look. |
| self.pythonExec = os.environ.get("PYSPARK_PYTHON", "python3") | ||
| self.pythonVer = "%d.%d" % sys.version_info[:2] | ||
|
|
||
| if sys.version_info[:2] < (3, 8): |
There was a problem hiding this comment.
just curious whether the version number could be something different from 3.7? if so perhaps the warning message could be something like Python support for version <= 3.7 is deprecated in Spark 3.4.
There was a problem hiding this comment.
Same though at first glance. But as we only support Python3.7+, I think there might be other version check so here it is 3.7 for sure? Not sure. If not, then revised error message would be better.
There was a problem hiding this comment.
Good question. It's unlikely because we did the following since Apache Spark 3.2 for a while. This is the first step and we did many efforts to kill 3.6 completely. The following code is removed at branch-3.3 after that. :)
spark/python/pyspark/context.py
Lines 233 to 239 in 0d11085
There was a problem hiding this comment.
In addition, Spark 3.4 requires Python 3.7+ at the installation stage explicitly.
Line 277 in 8628c15
|
Thank you, @viirya , @sunchao , @huaxingao , @ueshin . Merged to master for Apache Spark 3.4. |
|
Thanks for the fix! |
What changes were proposed in this pull request?
This PR aims to deprecate Python 3.7 support at Apache Spark 3.4.0.
Why are the changes needed?
Apache Spark 3.4 will be released on February 2023 and will be supported for next 18 months.
Before Spark 3.4.1, Python 3.7 is going to reach
End Of Supporton 2023-06-27. Although Apache Spark 3.4 will work with Python 3.7 still for a while, there is no proper and official way to support Python 3.7 from that time.Does this PR introduce any user-facing change?
Yes, but the users will see only a deprecation warning log and docs.
How was this patch tested?
Pass the CIs.