malinjawi opened a new pull request, #11869:
URL: https://github.com/apache/gluten/pull/11869

   ## What changes are proposed in this pull request?
   
   Fixes #14721.
   
   This PR works around a macOS-specific native validation failure in the Velox 
backend when the effective Spark session timezone is `GMT`.
   
   Based on the discussion in #14721, the underlying behavior is likely related 
to upstream Folly/Velox timezone handling on macOS rather than a general Spark 
semantics problem. This patch keeps the workaround on the Gluten side so Spark 
session timezone values do not block native validation and execution in the 
Velox path.
   
   The changes in this PR are:
   
   - normalize `GMT` and `GMT+/-offset` session timezone values to 
`UTC`-equivalent forms before passing them into native Velox query config
   - use the runtime session timezone in `SubstraitToVeloxPlanValidator` 
instead of hardcoding `GMT`
   - apply the same normalization when setting the Velox writer timezone config
   - add a regression test covering execution with 
`spark.sql.session.timeZone=GMT`
   
   ## How was this patch tested?
   
   - reproduced the failure on a clean unpatched checkout on macOS after a 
fresh native rebuild
   - verified the failure is:
     - `session 'session_timezone' set with invalid value 'GMT'`
   - rebuilt native Gluten/Velox with this patch
   - ran the new targeted regression test in `MiscOperatorSuite`:
     - `cast date to timestamp with GMT session timezone`
   - the targeted regression test passes with this patch
   
   ## Was this patch authored or co-authored using generative AI tooling?
   
   Generated-by: IBM BOB
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to