Skip to content

chore: enable ansi by default for Spark 4 tests#4368

Closed
comphead wants to merge 3 commits into
apache:mainfrom
comphead:ansi
Closed

chore: enable ansi by default for Spark 4 tests#4368
comphead wants to merge 3 commits into
apache:mainfrom
comphead:ansi

Conversation

@comphead
Copy link
Copy Markdown
Contributor

Which issue does this PR close?

Closes #.

Rationale for this change

CometTestBase was unconditionally pinning ANSI to false, which meant the Spark 4.0 / 4.1 / 4.2 test profiles never actually exercised the ANSI behavior that real Spark 4 users get out of the box.
Tests that pass under Comet today may regress in production because we never run them with the same defaults.

What changes are included in this PR?

How are these changes tested?

conf.set("spark.ui.enabled", "false")
conf.set(SQLConf.SHUFFLE_PARTITIONS, 10) // reduce parallelism in tests
conf.set(SQLConf.ANSI_ENABLED.key, "false")
val sparkMajorVersion =
Copy link
Copy Markdown
Contributor Author

@comphead comphead May 19, 2026

Choose a reason for hiding this comment

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

its to follow defaults, however in future we need to include ansi to the test as ConfigMatrix

UPD: for some case ConfigMatrix won't work and current approach is to have separate files

conf.set("spark.ui.enabled", "false")
conf.set(SQLConf.SHUFFLE_PARTITIONS, 10) // reduce parallelism in tests
conf.set(SQLConf.ANSI_ENABLED.key, "false")
val sparkMajorVersion =
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Isn't there a isSpark40Plus boolean already available?

@andygrove
Copy link
Copy Markdown
Member

replaced with #4370 - thanks @comphead

@andygrove andygrove closed this May 20, 2026
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.

3 participants