Skip to content

[SPARK-59357][CONNECT][TEST] Improve Python client plan test coverage - #58643

Open
zhengruifeng wants to merge 2 commits into
apache:masterfrom
zhengruifeng:py-connect-plan-coverage-dev-6
Open

[SPARK-59357][CONNECT][TEST] Improve Python client plan test coverage#58643
zhengruifeng wants to merge 2 commits into
apache:masterfrom
zhengruifeng:py-connect-plan-coverage-dev-6

Conversation

@zhengruifeng

@zhengruifeng zhengruifeng commented Sep 9, 2026

Copy link
Copy Markdown
Contributor

What changes were proposed in this pull request?

This PR addresses SPARK-59357.

This PR expands the Python Spark Connect plan-only tests for DataFrame APIs. It adds protobuf plan assertions for:

  • projections and aggregation modes;
  • as-of, lateral, and nearest-by joins;
  • column additions, metadata, and renames;
  • watermark, hint, transpose, and toDF operations;
  • zipWithIndex, repartitionById, and deduplication within a watermark.

It also updates the existing union alias coverage to exercise unionAll directly.

Why are the changes needed?

These DataFrame APIs previously lacked focused tests of the protobuf plans generated by the Python client. The additional plan-only coverage catches client-side serialization regressions without requiring a running Spark server.

Does this PR introduce any user-facing change?

No.

How was this patch tested?

python3 -u python/run-tests.py --testnames pyspark.sql.tests.connect.test_connect_plan

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

Generated-by: OpenAI Codex (GPT-5)

@zhengruifeng zhengruifeng changed the title [MINOR][CONNECT] Improve Python client plan test coverage [SPARK-59357][CONNECT] Improve Python client plan test coverage Sep 9, 2026
@zhengruifeng
zhengruifeng force-pushed the py-connect-plan-coverage-dev-6 branch from 5f590d4 to e8c02c3 Compare September 9, 2026 06:20
@zhengruifeng zhengruifeng changed the title [SPARK-59357][CONNECT] Improve Python client plan test coverage [SPARK-59357][CONNECT][TEST] Improve Python client plan test coverage Sep 9, 2026

@uros-b uros-b left a comment

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.

There are some conflicts, but otherwise looks good!

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.

2 participants