Skip to content

[SPARK-58282][PYTHON][DOCS] Refresh PySpark README and clarify project scope#57452

Open
nchammas wants to merge 7 commits into
apache:masterfrom
nchammas:pyspark-readme
Open

[SPARK-58282][PYTHON][DOCS] Refresh PySpark README and clarify project scope#57452
nchammas wants to merge 7 commits into
apache:masterfrom
nchammas:pyspark-readme

Conversation

@nchammas

@nchammas nchammas commented Jul 23, 2026

Copy link
Copy Markdown
Contributor

What changes were proposed in this pull request?

Refresh the PySpark README.

Key changes:

  • Remove the "experimental" label for the Python distribution of Spark.
  • Add a summary of the different packages on PyPI and scope claims about JARs being included accordingly.
  • Use the term "distribution" more deliberately and clarify Python vs. "Full" distribution.

Why are the changes needed?

The README hasn't seen a significant update in many years and contains some obsolete language.

Clarifying the intended use of PySpark vs. "Full" Spark will also help focus related discussions coming out of the effort to potentially introduce a new CLI in #57313.

Does this PR introduce any user-facing change?

Documentation only.

How was this patch tested?

No testing.

Was this patch authored or co-authored using generative AI tooling?

No.

Comment thread python/README.md Outdated
This packaging is currently experimental and may change in future versions (although we will do our best to keep compatibility).
Using PySpark requires the Spark JARs, and if you are building this from source please see the builder instructions at
["Building Spark"](https://spark.apache.org/docs/latest/building-spark.html).
PySpark is not intended to be a complete distribution of Spark. It's meant for local development or for interacting with an existing cluster (be it Spark standalone, YARN, or Kubernetes). Using PySpark to set up a new standalone Spark cluster is not supported. To set up a standalone cluster you need to [use the full distribution of Spark](https://spark.apache.org/downloads.html).

@nchammas nchammas Jul 23, 2026

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This wording change from "does not contain the tools required" to "is not supported" is deliberate. I would like us to have the freedom to add more sbin scripts (like for Connect) to the pyspark package while making it clear that we don't support using PySpark to create a cluster.

I will propose packaging additional sbin scripts with PySpark in a separate PR.

@nchammas

Copy link
Copy Markdown
Contributor Author

Comment thread python/README.md Outdated
See also [Dependencies](https://spark.apache.org/docs/latest/api/python/getting_started/install.html#dependencies) for production, and [pyproject.toml](https://github.com/apache/spark/blob/master/pyproject.toml) for development.
At its core PySpark depends on Py4J, but some additional sub-packages have their own extra requirements for some features. See [Dependencies](https://spark.apache.org/docs/latest/api/python/getting_started/install.html#dependencies) for the full list of production dependencies and [pyproject.toml](https://github.com/apache/spark/blob/master/pyproject.toml) for development dependencies.

PySpark also requires the Spark JARs, which are included in this distribution. If you are building this distribution from source please see [the builder instructions](https://spark.apache.org/docs/latest/building-spark.html).

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The new line "PySpark also requires the Spark JARs, which are included in this distribution" is inaccurate for two of the three PyPI packages that reuse this file verbatim as their long_description. Confirmed against master: python/packaging/ {classic,connect,client}/setup.py all read README.md into long_description.

The classic pyspark package bundles the assembly jars (statement true), but pyspark-connect obtains them only transitively via its pyspark==VERSION dependency, and pyspark-client bundles no jars and does not even depend on pyspark, so on those two PyPI pages "included in this distribution" is false.

A one-word hedge ("included in the PySpark distribution", or noting that the client/connect packages obtain them via the pyspark dependency) fixes it.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oh, I didn't realize that packages other than pyspark use the same README. Let me take another look.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

OK this is a good catch, and it looks like the old text is also inaccurate due to the shared use of this README. python-client, for example, doesn't require Spark JARs and doesn't even depend on Py4J.

I'll update this accordingly.

@uros-b

uros-b commented Jul 23, 2026

Copy link
Copy Markdown
Member

I left just one comment, but otherwise looks good

@gaogaotiantian

Copy link
Copy Markdown
Contributor

Yeah I think we need at least @HyukjinKwon and @zhengruifeng to go over this change to confirm the newly added explanation is correct and the deleted information is outdated.

Comment thread python/README.md

Spark is a unified analytics engine for large-scale data processing. It provides
high-level APIs in Scala, Java, Python, and R, and an optimized engine that
high-level APIs in Scala, Java, and Python, and an optimized engine that

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

we deprecated R but I think the support is still there (?)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants