shivadarshan-devadiga opened a new issue, #13636:
URL: https://github.com/apache/gluten/issues/13636

   ### Backend
   
   CH (ClickHouse)
   
   ### Bug description
   
   ### What happens
   
   `GlutenHiveSQLQueryCHSuite` has the same problem #12856 fixed in 
`GlutenHiveSQLQuerySuite`. Each case creates a persistent Hive table, runs its 
assertions, and only then drops it with 
`spark.sessionState.catalog.dropTable(...)`, outside `withTable` or a 
`finally`. Any failure in between skips the drop. Two of the cases also start 
with a `DROP TABLE IF EXISTS`, so they mix two cleanup paths.
   
   In 
`gluten-ut/spark35/src/test/scala/org/apache/spark/sql/hive/execution/GlutenHiveSQLQueryCHSuite.scala`:
   
   - `testGluten("5182: Fix failed to parse post join filters")` 
(`test_5182_0`, `test_5182_1`) at `:39`, with `DROP TABLE IF EXISTS` at 
`:42`/`:43` and the drops at `:67`/`:71`
   - `testGluten("5249: Reading csv may throw Unexpected empty column")` 
(`test_5249`) at `:77`, with `DROP TABLE IF EXISTS` at `:78` and the drop at 
`:95`
   - `testGluten("GLUTEN-7116: Support outer explode")` (`test_7116`) at 
`:101`, with the drop at `:113`
   
   All three exist in all five 
`gluten-ut/spark34`/`spark35`/`spark40`/`spark41`/`spark42` modules.
   
   ### Why it matters
   
   As in #12856: the Hive suites share one `TestHive` singleton, so when an 
assertion fails, the table stays in the metastore and the warehouse, and later 
cases in the same JVM see it.
   
   ### History
   
   The 5182 and 5249 cases came from #5485 (2024), and the 7116 case from #7207 
(2024). #13405 fixed `GlutenHiveSQLQuerySuite` and `GlutenHiveSQLQueryCHSuite` 
was left as it was.
   
   ### Suggested fix
   
   Wrap each case in `withTable(...)` for the tables it creates, and remove the 
manual `DROP TABLE IF EXISTS` and `dropTable` calls, plus the then-unused 
`TableIdentifier` import, across all five modules, as #13405 did.
   
   
   ### Gluten version
   
   _No response_
   
   ### Spark version
   
   None
   
   ### Spark configurations
   
   _No response_
   
   ### System information
   
   _No response_
   
   ### Relevant logs
   
   ```bash
   
   ```


-- 
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]

  • [I] [CH][UT] GlutenHiveSQLQ... shivadarshan-devadiga (via GitHub) via commits

Reply via email to