andygrove commented on code in PR #7505:
URL: https://github.com/apache/datafusion-comet/pull/7505#discussion_r4513171071


##########
spark/src/main/scala/org/apache/comet/rules/EliminateRedundantTransitions.scala:
##########
@@ -112,22 +112,27 @@ case class EliminateRedundantTransitions(session: 
SparkSession)
       case ColumnarToRowExec(range: CometRangeExec) =>
         range.originalPlan
       case c @ ColumnarToRowExec(child) if hasCometNativeChild(child, 
containsCometPlanMemo) =>
-        val op = createColumnarToRowExec(child)
-        if (c.logicalLink.isEmpty) {
-          op.unsetTagValue(SparkPlan.LOGICAL_PLAN_TAG)
-          op.unsetTagValue(SparkPlan.LOGICAL_PLAN_INHERITED_TAG)
+        if (containsVariantType(child.schema)) {
+          // TODO: Remove this fallback once Comet columnar-to-row conversion 
supports Variant
+          // getters and Spark's Variant UnsafeRow encoding.
+          // https://github.com/apache/datafusion-comet/issues/5436
+          withFallbackReason(
+            c,
+            "Comet columnar-to-row conversion does not support type 
VariantType")

Review Comment:
   Good catch. `checkNative` now asserts that the plan carries `Comet 
columnar-to-row conversion does not support type VariantType` whenever its 
output contains a Variant column (5498e664da). I checked it bites: with the 
expected string changed, 7 of the 13 tests in `CometVariantProjectionSuite` 
fail, and with the real string all 13 pass.



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