From 748ac667babb37c3efafa208c09c1f05ce9fea44 Mon Sep 17 00:00:00 2001 From: Matthieu Baechler Date: Mon, 29 Apr 2024 17:55:59 +0200 Subject: [PATCH 1/9] Enable new Xsource:3-cross compilation flag for scala 2.13.14 --- webapp/sources/pom.xml | 9 +++------ .../rudder/repository/jdbc/ReportingServiceTest.scala | 2 -- .../com/normation/rudder/rest/RudderJsonResponse.scala | 7 ++----- 3 files changed, 5 insertions(+), 13 deletions(-) diff --git a/webapp/sources/pom.xml b/webapp/sources/pom.xml index 487506ff9d6..a984b52fd71 100644 --- a/webapp/sources/pom.xml +++ b/webapp/sources/pom.xml @@ -171,7 +171,7 @@ limitations under the License. org.scalameta semanticdb-scalac_${scala-version} - 4.8.14 + 4.9.1 @@ -184,7 +184,7 @@ limitations under the License. -Xlint:_,-nullary-unit,-missing-interpolator -Yno-adapted-args -Ywarn-dead-code -Ywarn-extra-implicit -Ywarn-inaccessible -Ywarn-infer-any -Ywarn-nullary-override -Ywarn-numeric-widen -Ywarn-unused:imports -Ywarn-unused:locals -Ywarn-unused:privates --> - -Xsource:3 + -Xsource:3-cross -deprecation -explaintypes -feature @@ -213,9 +213,6 @@ limitations under the License. -Wconf:cat=unused-nowarn&src=com/normation/utils/Version.scala:s,cat=unused-nowarn&src=com/normation/rudder/services/policies/InterpolatedValueCompiler.scala:s - - - -Wconf:msg=constructor modifiers are assumed by synthetic:s -Xmx${jvmArg-Xmx} @@ -422,7 +419,7 @@ limitations under the License. 8.1 8.1.3-SNAPSHOT - 2.13.12 + 2.13.14 2.13 - - -Xsource:3-cross -deprecation -explaintypes -feature @@ -168,27 +160,7 @@ limitations under the License. -language:existentials -language:higherKinds -language:implicitConversions - -Xcheckinit - - -Xfatal-warnings - -Xlint:_,-nonlocal-return,-nullary-unit,-missing-interpolator,-byname-implicit - -Ywarn-dead-code - - -Ywarn-extra-implicit - -Ywarn-numeric-widen - -Ywarn-unused:imports - -Ywarn-unused:locals - -Ywarn-unused:privates - -Ywarn-unused:implicits - -Ywarn-unused:privates - -Ybackend-parallelism8 - -Ycache-plugin-class-loader:last-modified - -Ycache-macro-class-loader:last-modified - - - -Wconf:cat=unused-nowarn&src=com/normation/utils/Version.scala:s,cat=unused-nowarn&src=com/normation/rudder/services/policies/InterpolatedValueCompiler.scala:s + -Xmax-inlines100 -Xmx${jvmArg-Xmx} @@ -387,7 +359,7 @@ limitations under the License. UTF-8 - 4.7.2 + 4.8.1 @@ -395,8 +367,8 @@ limitations under the License. 8.1 8.1.3-SNAPSHOT - 2.13.14 - 2.13 + 3.3.3 + 3 org.scalaj - scalaj-http_${scala-binary-version} + scalaj-http_2.13 ${scalaj-version} @@ -144,7 +144,7 @@ along with Rudder. If not, see . net.liftweb - lift-testkit_${scala-binary-version} + lift-testkit_2.13 ${lift-version} test diff --git a/webapp/sources/rudder/rudder-rest/src/test/scala/com/normation/rudder/rest/RestTestSetUp.scala b/webapp/sources/rudder/rudder-rest/src/test/scala/com/normation/rudder/rest/RestTestSetUp.scala index f5281552eed..ac6bd041d16 100644 --- a/webapp/sources/rudder/rudder-rest/src/test/scala/com/normation/rudder/rest/RestTestSetUp.scala +++ b/webapp/sources/rudder/rudder-rest/src/test/scala/com/normation/rudder/rest/RestTestSetUp.scala @@ -665,7 +665,7 @@ class RestTestSetUp { override def default(withId: String): DirectiveField = new DirectiveField { self => type ValueType = String def manifest: ClassTag[String] = classTag[String] - lazy val id = withId + val id = withId def name = id override val uniqueFieldId: Box[String] = Full(id) protected var _x: String = getDefaultValue diff --git a/webapp/sources/rudder/rudder-templates-cli/pom.xml b/webapp/sources/rudder/rudder-templates-cli/pom.xml index 96b10f9b38a..172949f3e31 100644 --- a/webapp/sources/rudder/rudder-templates-cli/pom.xml +++ b/webapp/sources/rudder/rudder-templates-cli/pom.xml @@ -86,12 +86,12 @@ along with Rudder. If not, see . net.liftweb - lift-json_${scala-binary-version} + lift-json_2.13 ${lift-version} net.liftweb - lift-common_${scala-binary-version} + lift-common_2.13 ${lift-version} diff --git a/webapp/sources/utils/pom.xml b/webapp/sources/utils/pom.xml index 98abb8c9df4..d2545ebd75e 100644 --- a/webapp/sources/utils/pom.xml +++ b/webapp/sources/utils/pom.xml @@ -43,11 +43,11 @@ limitations under the License. net.liftweb - lift-common_${scala-binary-version} + lift-common_2.13 net.liftweb - lift-json_${scala-binary-version} + lift-json_2.13 com.lihaoyi