Skip to content

[GLUTEN-11916][VL] Enable 7 Spark 4.1 TODO SQL query test files#12146

Open
rdtr wants to merge 1 commit into
apache:mainfrom
rdtr:spark41-enable-todo-tests
Open

[GLUTEN-11916][VL] Enable 7 Spark 4.1 TODO SQL query test files#12146
rdtr wants to merge 1 commit into
apache:mainfrom
rdtr:spark41-enable-todo-tests

Conversation

@rdtr
Copy link
Copy Markdown

@rdtr rdtr commented May 26, 2026

Description:

Summary

  • Enable 7 of 11 TODO SQL query test files in spark41 VeloxSQLQueryTestSettings ([VL] Spark 4.1: Diagnose and enable TODO SQL query test files #11916)
  • 6 tests were already passing on current main — they just needed verification and uncomment
  • Fix golden file for type-coercion-edge-cases.sql: Spark 4.1 changed MAP field access behavior — col2.field on
    MAP<BIGINT, DOUBLE> now uses semi-structured field extraction (returns struct<field:double>) instead of attempting
    CAST("field" AS BIGINT) which threw CAST_INVALID_INPUT in ANSI mode

Enabled tests

File What was needed
cast.sql Already passing — uncomment TODO
describe.sql Already passing — uncomment TODO
literals.sql Already passing — uncomment TODO
nonansi/cast.sql Already passing (imports cast.sql) — uncomment TODO
nonansi/literals.sql Already passing (imports literals.sql) — uncomment TODO
nonansi/st-functions.sql Already passing — uncomment TODO
type-coercion-edge-cases.sql Golden file update for Spark 4.1 behavior change

Remaining 4 TODOs (triaged, not in this PR)

  • subquery/exists-subquery/exists-orderby-limit.sql -> ANSI fallback causes INTERNAL_ERROR on Spark 4.1
    OneRowRelationExec null session
  • scripting/randomly_generated_scripts.sql -> NPE in SQL scripting exception handler condition handling
  • st-functions.sql -> Geospatial types (GEOGRAPHY/GEOMETRY) new in Spark 4.1, not supported in Velox
  • variant-field-extractions.sql -> Variant type not supported ([VL] Spark 4.x: Support Variant type #11371)

I will check them too.

Test plan

  • CI: spark-test-spark41-slow (runs GlutenSQLQueryTestSuite with ExtendedSQLTest tag)

  Enable 7 of 11 TODO SQL query test files in spark41 VeloxSQLQueryTestSettings:
  - cast.sql, describe.sql, literals.sql (+ nonansi imports): already passing
  - nonansi/st-functions.sql: already passing
  - type-coercion-edge-cases.sql: fix golden file for Spark 4.1 semi-structured
    field access behavior change (col2.field on MAP now returns field extraction
    instead of CAST_INVALID_INPUT error)

  Remaining 4 TODOs triaged to separate issues:
  - subquery/exists-subquery/exists-orderby-limit.sql: ANSI fallback + OFFSET
  - scripting/randomly_generated_scripts.sql: NPE in condition handling
  - st-functions.sql: geospatial types (new Spark 4.1, not in Velox)
  - variant-field-extractions.sql: Variant type (apache#11371)
@github-actions github-actions Bot added the CORE works for Gluten Core label May 26, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

CORE works for Gluten Core

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant