Copilot commented on code in PR #2014:
URL: https://github.com/apache/auron/pull/2014#discussion_r2853911477
##########
pom.xml:
##########
@@ -916,6 +1091,33 @@
</execution>
</executions>
</plugin>
+ <plugin>
+ <groupId>net.alchim31.maven</groupId>
+ <artifactId>scala-maven-plugin</artifactId>
+ <configuration>
+ <args combine.self="override">
+ <arg>-Ymacro-annotations</arg>
+ <arg>-Wconf:cat=deprecation:wv,any:e</arg>
+ <arg>-Wconf:cat=other-nullary-override:s</arg>
+
<arg>-Wconf:msg=^(?=.*?method|value|type|object|trait|inheritance)(?=.*?deprecated)(?=.*?since
2.13).+$:s</arg>
+ <arg>-Wconf:msg=Auto-application to \`\(\)\` is
deprecated:s</arg>
+ <arg>-Wconf:msg=object JavaConverters in package collection is
deprecated:s</arg>
+ <arg>-Wconf:cat=unchecked&msg=outer reference:s</arg>
+ <arg>-Wconf:cat=unchecked&msg=eliminated by erasure:s</arg>
+ <arg>-Wconf:cat=unused-nowarn:s</arg>
+ <arg>-Wconf:msg=early initializers are deprecated:s</arg>
+ <arg>-Wconf:cat=other-match-analysis:s</arg>
+ <arg>-Wconf:cat=feature-existentials:s</arg>
+ </args>
Review Comment:
The args configuration in the spark-4.1 profile is missing several compiler
arguments that are present in the scala-2.13 profile (lines 1227-1250).
Specifically missing:
- `-deprecation`
- `-feature`
- `-Ywarn-unused`
- `-Xfatal-warnings`
- `-Wconf:msg=method newInstance in class Class is deprecated:s`
- `-Wconf:msg=class ThreadDeath in package lang is deprecated:s`
These should be included to maintain consistency with the scala-2.13 profile
that would have been used previously.
##########
pom.xml:
##########
@@ -778,7 +778,31 @@
<sparkVersion>3.0.3</sparkVersion>
<shortSparkVersion>3.0</shortSparkVersion>
<nettyVersion>4.1.47.Final</nettyVersion>
+ <scalaVersion>2.12</scalaVersion>
+ <scalaLongVersion>2.12.18</scalaLongVersion>
</properties>
+ <build>
+ <plugins>
+ <plugin>
+ <groupId>net.alchim31.maven</groupId>
+ <artifactId>scala-maven-plugin</artifactId>
+ <configuration>
+ <compilerPlugins combine.self="override">
+ <compilerPlugin>
+ <groupId>org.scalameta</groupId>
+
<artifactId>semanticdb-scalac_${scalaLongVersion}</artifactId>
+ <version>${semanticdb.version}</version>
+ </compilerPlugin>
+ <compilerPlugin>
+ <groupId>org.scalamacros</groupId>
+ <artifactId>paradise_${scalaLongVersion}</artifactId>
+ <version>${scalamacros.paradise.version}</version>
+ </compilerPlugin>
+ </compilerPlugins>
+ </configuration>
Review Comment:
The scala-2.12 profile (lines 1177-1207) will automatically activate when
scalaVersion=2.12 due to its activation condition. Since all Spark 3.x profiles
now set this property, both the Spark profile and the scala-2.12 profile will
be active simultaneously.
While the use of `combine.self="override"` in the Spark profiles should
prevent configuration merging, this creates a potential maintenance issue and
could lead to unexpected behavior if the override attribute is removed or if
Maven's profile merging behavior changes. Consider either:
1. Removing the scala-2.12 and scala-2.13 profiles entirely if they are no
longer needed
2. Modifying their activation conditions to prevent conflicts with Spark
profiles
##########
pom.xml:
##########
@@ -874,6 +1020,33 @@
</execution>
</executions>
</plugin>
+ <plugin>
+ <groupId>net.alchim31.maven</groupId>
+ <artifactId>scala-maven-plugin</artifactId>
+ <configuration>
+ <args combine.self="override">
+ <arg>-Ymacro-annotations</arg>
+ <arg>-Wconf:cat=deprecation:wv,any:e</arg>
+ <arg>-Wconf:cat=other-nullary-override:s</arg>
+
<arg>-Wconf:msg=^(?=.*?method|value|type|object|trait|inheritance)(?=.*?deprecated)(?=.*?since
2.13).+$:s</arg>
+ <arg>-Wconf:msg=Auto-application to \`\(\)\` is
deprecated:s</arg>
+ <arg>-Wconf:msg=object JavaConverters in package collection is
deprecated:s</arg>
+ <arg>-Wconf:cat=unchecked&msg=outer reference:s</arg>
+ <arg>-Wconf:cat=unchecked&msg=eliminated by erasure:s</arg>
+ <arg>-Wconf:cat=unused-nowarn:s</arg>
+ <arg>-Wconf:msg=early initializers are deprecated:s</arg>
+ <arg>-Wconf:cat=other-match-analysis:s</arg>
+ <arg>-Wconf:cat=feature-existentials:s</arg>
+ </args>
Review Comment:
The args configuration in the spark-4.0 profile is missing several compiler
arguments that are present in the scala-2.13 profile (lines 1227-1250).
Specifically missing:
- `-deprecation`
- `-feature`
- `-Ywarn-unused`
- `-Xfatal-warnings`
- `-Wconf:msg=method newInstance in class Class is deprecated:s`
- `-Wconf:msg=class ThreadDeath in package lang is deprecated:s`
These should be included to maintain consistency with the scala-2.13 profile
that would have been used previously.
##########
pom.xml:
##########
@@ -833,7 +953,31 @@
<sparkVersion>3.5.8</sparkVersion>
<shortSparkVersion>3.5</shortSparkVersion>
<nettyVersion>4.1.96.Final</nettyVersion>
+ <scalaVersion>2.12</scalaVersion>
+ <scalaLongVersion>2.12.18</scalaLongVersion>
</properties>
+ <build>
+ <plugins>
+ <plugin>
+ <groupId>net.alchim31.maven</groupId>
+ <artifactId>scala-maven-plugin</artifactId>
+ <configuration>
+ <compilerPlugins combine.self="override">
+ <compilerPlugin>
+ <groupId>org.scalameta</groupId>
+
<artifactId>semanticdb-scalac_${scalaLongVersion}</artifactId>
+ <version>${semanticdb.version}</version>
+ </compilerPlugin>
+ <compilerPlugin>
+ <groupId>org.scalamacros</groupId>
+ <artifactId>paradise_${scalaLongVersion}</artifactId>
+ <version>${scalamacros.paradise.version}</version>
+ </compilerPlugin>
+ </compilerPlugins>
+ </configuration>
Review Comment:
There is significant duplication of the scala-maven-plugin configuration
across all six Spark 3.x profiles (spark-3.0 through spark-3.5). Each profile
contains identical compiler plugin configurations (semanticdb-scalac and
paradise).
Consider extracting this common configuration into a shared parent profile
or property to reduce duplication and simplify maintenance. For example, create
a spark-3.x parent profile that all Spark 3.x profiles inherit from.
--
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]