RussellSpitzer commented on code in PR #12494: URL: https://github.com/apache/iceberg/pull/12494#discussion_r2047241901
########## spark/v4.0/spark/src/main/java/org/apache/iceberg/spark/actions/SparkShufflingDataRewriter.java: ########## @@ -161,7 +161,20 @@ private LogicalPlan sortPlan(LogicalPlan plan, SortOrder[] ordering, int numShuf } private Dataset<Row> transformPlan(Dataset<Row> df, Function<LogicalPlan, LogicalPlan> func) { - return new Dataset<>(spark(), func.apply(df.logicalPlan()), df.encoder()); + if (!(spark() instanceof org.apache.spark.sql.classic.SparkSession)) { + throw new IllegalArgumentException( + "spark is supposed to be org.apache.spark.sql.classic.SparkSession"); Review Comment: Similar concerns about these error messages as above -- 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: issues-unsubscr...@iceberg.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: issues-unsubscr...@iceberg.apache.org For additional commands, e-mail: issues-h...@iceberg.apache.org