-
Notifications
You must be signed in to change notification settings - Fork 94
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
breaking: Update to Scala 3.3.3
#507
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,23 +1,21 @@ | ||
inThisBuild( | ||
Seq( | ||
scalaVersion := "2.13.13", | ||
scalacOptions := Seq("-deprecation", "-feature", "-unchecked", "-Xlint", "-Xfatal-warnings") | ||
) | ||
) | ||
inThisBuild(Seq(scalaVersion := "3.3.3")) | ||
|
||
def commonSettings = | ||
Seq(scalacOptions := { | ||
val toFilter = Set("-deprecation:false") | ||
scalacOptions.value.filterNot(toFilter) ++ Seq("-deprecation") | ||
}) | ||
|
||
name := "codacy-coverage-reporter" | ||
|
||
// Runtime dependencies | ||
libraryDependencies ++= Seq( | ||
"com.github.alexarchambault" %% "case-app" % "2.1.0-M26", | ||
"org.wvlet.airframe" %% "airframe-log" % "22.3.0" | ||
"com.github.alexarchambault" %% "case-app" % "2.1.0-M28", | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 🙃 There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 🤷♂️ |
||
"org.wvlet.airframe" %% "airframe-log" % "24.6.0" | ||
) | ||
|
||
// Test dependencies | ||
libraryDependencies ++= Seq( | ||
"org.scalatest" %% "scalatest" % "3.0.8" % "it,test", | ||
"org.mockito" %% "mockito-scala-scalatest" % "1.7.1" % Test | ||
) | ||
libraryDependencies ++= Seq(scalatest % "it,test", "org.scalamock" %% "scalamock" % "6.0.0" % Test) | ||
|
||
assembly / mainClass := Some("com.codacy.CodacyCoverageReporter") | ||
assembly / assemblyMergeStrategy := { | ||
|
@@ -72,24 +70,30 @@ nativeImageOptions := Seq( | |
|
||
dependsOn(coverageParser) | ||
|
||
commonSettings | ||
|
||
val scalatest = "org.scalatest" %% "scalatest" % "3.2.18" | ||
|
||
lazy val apiScala = project | ||
.in(file("api-scala")) | ||
.settings( | ||
commonSettings, | ||
libraryDependencies ++= Seq( | ||
"com.typesafe.play" %% "play-json" % "2.8.2", | ||
"org.scalaj" %% "scalaj-http" % "2.4.2", | ||
"com.typesafe.play" %% "play-json" % "2.10.5", | ||
("org.scalaj" %% "scalaj-http" % "2.4.2").cross(CrossVersion.for3Use2_13), | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. What is the ideia here? That lib is not available for Scala3, and with this we are relying on the one from 2.13? (It also seems deprecated, so I guess we will want to swap at some point) There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Exactly! |
||
"org.eclipse.jgit" % "org.eclipse.jgit" % "4.11.9.201909030838-r", | ||
"org.scalatest" %% "scalatest" % "3.0.8" % Test | ||
scalatest % Test | ||
) | ||
) | ||
|
||
lazy val coverageParser = project | ||
.in(file("coverage-parser")) | ||
.settings( | ||
commonSettings, | ||
libraryDependencies ++= Seq( | ||
"com.codacy" %% "codacy-plugins-api" % "5.2.0", | ||
"org.scala-lang.modules" %% "scala-xml" % "1.2.0", | ||
"org.scalatest" %% "scalatest" % "3.0.8" % Test | ||
"com.codacy" %% "codacy-plugins-api" % "8.1.4", | ||
"org.scala-lang.modules" %% "scala-xml" % "2.3.0", | ||
scalatest % Test | ||
) | ||
) | ||
.dependsOn(apiScala) | ||
|
@@ -102,6 +106,3 @@ ThisBuild / assemblyMergeStrategy := { | |
val oldStrategy = (ThisBuild / assemblyMergeStrategy).value | ||
oldStrategy(x) | ||
} | ||
|
||
// required to upgrade org.scoverage.sbt-scoverage.2.0.6 | ||
ThisBuild / libraryDependencySchemes += "org.scala-lang.modules" %% "scala-xml" % VersionScheme.Always |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What is happening here and why do we need it?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There were two issues that were failing compilation because of
-Xfatal-warnings
and couldn't be seen because of the-deprecation:false
setting incodacy-sbt
. Maybe we need to revisitscalacOptions
in codacy-sbt but until that day this removes that option and adds-deprecation
.