From a91d94ce1b9b45d0711061b752316699a6679e27 Mon Sep 17 00:00:00 2001 From: Arnout Engelen Date: Tue, 29 Jan 2019 12:29:07 +0100 Subject: [PATCH 1/7] Scala 2.13.0-M5 support --- .travis.yml | 1 + project/Dependencies.scala | 5 +++-- project/plugins.sbt | 2 +- .../test/java/akka/grpc/javadsl/ConcatOrNotFoundTest.java | 2 +- runtime/src/test/scala/akka/grpc/JUnitEventually.scala | 2 +- 5 files changed, 7 insertions(+), 5 deletions(-) diff --git a/.travis.yml b/.travis.yml index 9d770ced1..f2bf6bad0 100644 --- a/.travis.yml +++ b/.travis.yml @@ -2,6 +2,7 @@ language: scala scala: - 2.12.8 + - 2.13.0-M5 # make sure to fetch enough commits, so that git describe still works git: diff --git a/project/Dependencies.scala b/project/Dependencies.scala index 77b9cdb9b..ee4e8facb 100644 --- a/project/Dependencies.scala +++ b/project/Dependencies.scala @@ -7,6 +7,7 @@ object Dependencies { object Versions { val scala212 = "2.12.8" + val scala213 = "2.13.0-M5" val akka = "2.5.20" val akkaHttp = "10.1.8" @@ -15,9 +16,9 @@ object Dependencies { val grpc = "1.20.0" // checked synced by GrpcVersionSyncCheckPlugin val config = "1.3.3" - val sslConfig = "0.3.6" + val sslConfig = "0.3.7" - val scalaTest = "3.0.5" + val scalaTest = "3.0.6-SNAP6" val maven = "3.5.4" } diff --git a/project/plugins.sbt b/project/plugins.sbt index 059dcf734..277b56de5 100644 --- a/project/plugins.sbt +++ b/project/plugins.sbt @@ -17,7 +17,7 @@ addSbtPlugin("org.foundweekends" % "sbt-bintray" % "0.5.5") // scripted testing libraryDependencies += "org.scala-sbt" %% "scripted-plugin" % sbtVersion.value -libraryDependencies += "com.thesamet.scalapb" %% "compilerplugin" % "0.8.4" +libraryDependencies += "com.thesamet.scalapb" %% "compilerplugin" % "0.9.0-M1" // #java-agent-plugin addSbtPlugin("com.lightbend.sbt" % "sbt-javaagent" % "0.1.5") diff --git a/runtime/src/test/java/akka/grpc/javadsl/ConcatOrNotFoundTest.java b/runtime/src/test/java/akka/grpc/javadsl/ConcatOrNotFoundTest.java index 896480aff..d610d9d7b 100644 --- a/runtime/src/test/java/akka/grpc/javadsl/ConcatOrNotFoundTest.java +++ b/runtime/src/test/java/akka/grpc/javadsl/ConcatOrNotFoundTest.java @@ -8,7 +8,7 @@ import akka.http.javadsl.model.HttpResponse; import akka.http.javadsl.model.StatusCodes; import org.junit.Test; -import org.scalatest.junit.JUnitSuite; +import org.scalatestplus.junit.JUnitSuite; import java.util.concurrent.CompletableFuture; import java.util.concurrent.CompletionStage; diff --git a/runtime/src/test/scala/akka/grpc/JUnitEventually.scala b/runtime/src/test/scala/akka/grpc/JUnitEventually.scala index 32767fb13..2c603e589 100644 --- a/runtime/src/test/scala/akka/grpc/JUnitEventually.scala +++ b/runtime/src/test/scala/akka/grpc/JUnitEventually.scala @@ -5,7 +5,7 @@ package akka.grpc import org.scalatest.concurrent.Eventually -import org.scalatest.junit.JUnitSuite +import org.scalatestplus.junit.JUnitSuite import org.scalatest.time.{ Millis, Span } abstract class JUnitEventually extends JUnitSuite with Eventually { From d9bb0f3082d2cc25039ba8846770ac03966f0d17 Mon Sep 17 00:00:00 2001 From: Arnout Engelen Date: Mon, 25 Mar 2019 11:32:57 +0100 Subject: [PATCH 2/7] Update scalatest, akka-http --- project/Dependencies.scala | 2 +- .../src/test/java/akka/grpc/javadsl/ConcatOrNotFoundTest.java | 2 +- runtime/src/test/scala/akka/grpc/JUnitEventually.scala | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/project/Dependencies.scala b/project/Dependencies.scala index ee4e8facb..cc4ddd3ed 100644 --- a/project/Dependencies.scala +++ b/project/Dependencies.scala @@ -18,7 +18,7 @@ object Dependencies { val config = "1.3.3" val sslConfig = "0.3.7" - val scalaTest = "3.0.6-SNAP6" + val scalaTest = "3.0.7" val maven = "3.5.4" } diff --git a/runtime/src/test/java/akka/grpc/javadsl/ConcatOrNotFoundTest.java b/runtime/src/test/java/akka/grpc/javadsl/ConcatOrNotFoundTest.java index d610d9d7b..896480aff 100644 --- a/runtime/src/test/java/akka/grpc/javadsl/ConcatOrNotFoundTest.java +++ b/runtime/src/test/java/akka/grpc/javadsl/ConcatOrNotFoundTest.java @@ -8,7 +8,7 @@ import akka.http.javadsl.model.HttpResponse; import akka.http.javadsl.model.StatusCodes; import org.junit.Test; -import org.scalatestplus.junit.JUnitSuite; +import org.scalatest.junit.JUnitSuite; import java.util.concurrent.CompletableFuture; import java.util.concurrent.CompletionStage; diff --git a/runtime/src/test/scala/akka/grpc/JUnitEventually.scala b/runtime/src/test/scala/akka/grpc/JUnitEventually.scala index 2c603e589..32767fb13 100644 --- a/runtime/src/test/scala/akka/grpc/JUnitEventually.scala +++ b/runtime/src/test/scala/akka/grpc/JUnitEventually.scala @@ -5,7 +5,7 @@ package akka.grpc import org.scalatest.concurrent.Eventually -import org.scalatestplus.junit.JUnitSuite +import org.scalatest.junit.JUnitSuite import org.scalatest.time.{ Millis, Span } abstract class JUnitEventually extends JUnitSuite with Eventually { From 0a06f234c86fdf02127d9dfe0e9bd260f620fa23 Mon Sep 17 00:00:00 2001 From: Arnout Engelen Date: Mon, 25 Mar 2019 12:38:16 +0100 Subject: [PATCH 3/7] Cross-building sbt config --- build.sbt | 13 ++++++++++--- .../scala/akka/grpc/interop/TestServiceImpl.scala | 4 ++-- project/Common.scala | 4 +++- project/build.properties | 2 +- 4 files changed, 16 insertions(+), 7 deletions(-) diff --git a/build.sbt b/build.sbt index e5f694987..a0d7f20b2 100644 --- a/build.sbt +++ b/build.sbt @@ -1,5 +1,5 @@ import akka.grpc.Dependencies -import akka.grpc.Dependencies.Versions.scala212 +import akka.grpc.Dependencies.Versions.{ scala212, scala213 } import akka.grpc.ProjectExtensions._ import akka.grpc.build.ReflectiveCodeGen @@ -28,6 +28,7 @@ lazy val codegen = Project( assemblyOption in assembly := (assemblyOption in assembly).value.copy( prependShellScript = Some(sbtassembly.AssemblyPlugin.defaultShellScript) ), + crossScalaVersions -= scala213, )) .settings(addArtifact(artifact in (Compile, assembly), assembly)) @@ -53,6 +54,7 @@ lazy val scalapbProtocPlugin = Project( assemblyOption in assembly := (assemblyOption in assembly).value.copy( prependShellScript = Some(sbtassembly.AssemblyPlugin.defaultShellScript) ), + crossScalaVersions -= scala213, )) .settings(addArtifact(artifact in (Compile, assembly), assembly)) @@ -65,6 +67,7 @@ lazy val mavenPlugin = Project( .settings(Seq( publishMavenStyle := true, crossPaths := false, + crossScalaVersions := Seq(scala212), )) .dependsOn(codegen) @@ -90,6 +93,7 @@ lazy val sbtPlugin = Project( }, scriptedBufferLog := false, crossSbtVersions := Seq("1.0.0"), + crossScalaVersions := Seq(scala212), ) .dependsOn(codegen) @@ -162,7 +166,8 @@ lazy val docs = Project( ), resolvers += Resolver.jcenterRepo, publishRsyncArtifact := makeSite.value -> "www/", - publishRsyncHost := "akkarepo@gustav.akka.io" + publishRsyncHost := "akkarepo@gustav.akka.io", + crossScalaVersions := List(scala212, scala213), ) lazy val pluginTesterScala = Project( @@ -206,5 +211,7 @@ lazy val root = Project( ) .settings( skip in publish := true, - unmanagedSources in (Compile, headerCreate) := (baseDirectory.value / "project").**("*.scala").get + unmanagedSources in (Compile, headerCreate) := (baseDirectory.value / "project").**("*.scala").get, + // https://github.com/sbt/sbt/issues/3465 + crossScalaVersions := List(), ) diff --git a/interop-tests/src/test/scala/akka/grpc/interop/TestServiceImpl.scala b/interop-tests/src/test/scala/akka/grpc/interop/TestServiceImpl.scala index 7d52e6cb7..d036e2199 100644 --- a/interop-tests/src/test/scala/akka/grpc/interop/TestServiceImpl.scala +++ b/interop-tests/src/test/scala/akka/grpc/interop/TestServiceImpl.scala @@ -63,7 +63,7 @@ class TestServiceImpl(implicit ec: ExecutionContext, mat: Materializer) extends Status.fromCodeValue(reqStatus.code).withDescription(reqStatus.message))) req }).mapConcat( - _.responseParameters.to[immutable.Seq]).via(parametersToResponseFlow) + _.responseParameters.toList).via(parametersToResponseFlow) override def halfDuplexCall(in: Source[StreamingOutputCallRequest, NotUsed]): Source[StreamingOutputCallResponse, NotUsed] = ??? @@ -77,7 +77,7 @@ class TestServiceImpl(implicit ec: ExecutionContext, mat: Materializer) extends } override def streamingOutputCall(in: StreamingOutputCallRequest): Source[StreamingOutputCallResponse, NotUsed] = - Source(in.responseParameters.to[immutable.Seq]).via(parametersToResponseFlow) + Source(in.responseParameters.toList).via(parametersToResponseFlow) override def unimplementedCall(in: Empty): Future[Empty] = ??? } diff --git a/project/Common.scala b/project/Common.scala index 9591c3170..04549f200 100644 --- a/project/Common.scala +++ b/project/Common.scala @@ -1,6 +1,7 @@ import sbt.Keys._ import sbt._ import sbt.plugins.JvmPlugin +import akka.grpc.Dependencies.Versions.{ scala212, scala213 } object Common extends AutoPlugin { @@ -33,6 +34,7 @@ object Common extends AutoPlugin { javacOptions ++= List( "-Xlint:unchecked", "-Xlint:deprecation" - ) + ), + crossScalaVersions := Seq(scala212, scala213), ) ++ akka.grpc.Formatting.formatSettings } diff --git a/project/build.properties b/project/build.properties index 72f902892..c0bab0494 100644 --- a/project/build.properties +++ b/project/build.properties @@ -1 +1 @@ -sbt.version=1.2.7 +sbt.version=1.2.8 From f7577db63d2b2078e989f4fa36accedb6df2d342 Mon Sep 17 00:00:00 2001 From: Arnout Engelen Date: Fri, 5 Apr 2019 12:20:02 +0200 Subject: [PATCH 4/7] Update scalapb to 0.9.0-M2 --- project/plugins.sbt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/project/plugins.sbt b/project/plugins.sbt index 277b56de5..c228b70db 100644 --- a/project/plugins.sbt +++ b/project/plugins.sbt @@ -17,7 +17,7 @@ addSbtPlugin("org.foundweekends" % "sbt-bintray" % "0.5.5") // scripted testing libraryDependencies += "org.scala-sbt" %% "scripted-plugin" % sbtVersion.value -libraryDependencies += "com.thesamet.scalapb" %% "compilerplugin" % "0.9.0-M1" +libraryDependencies += "com.thesamet.scalapb" %% "compilerplugin" % "0.9.0-M2" // #java-agent-plugin addSbtPlugin("com.lightbend.sbt" % "sbt-javaagent" % "0.1.5") From fd5a54b84c5f52fd7775ab93ed03a99c25b5f7fe Mon Sep 17 00:00:00 2001 From: Arnout Engelen Date: Mon, 15 Apr 2019 13:00:11 +0200 Subject: [PATCH 5/7] Update scalapb to M3 --- project/plugins.sbt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/project/plugins.sbt b/project/plugins.sbt index c228b70db..8e2e102ce 100644 --- a/project/plugins.sbt +++ b/project/plugins.sbt @@ -17,7 +17,7 @@ addSbtPlugin("org.foundweekends" % "sbt-bintray" % "0.5.5") // scripted testing libraryDependencies += "org.scala-sbt" %% "scripted-plugin" % sbtVersion.value -libraryDependencies += "com.thesamet.scalapb" %% "compilerplugin" % "0.9.0-M2" +libraryDependencies += "com.thesamet.scalapb" %% "compilerplugin" % "0.9.0-M3" // #java-agent-plugin addSbtPlugin("com.lightbend.sbt" % "sbt-javaagent" % "0.1.5") From 948147c45db18d0cc0cc3aa9a92d488acabaa3e3 Mon Sep 17 00:00:00 2001 From: Arnout Engelen Date: Wed, 15 May 2019 07:38:03 +0200 Subject: [PATCH 6/7] Update scalapb to 0.9.0-M4 --- project/plugins.sbt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/project/plugins.sbt b/project/plugins.sbt index 8e2e102ce..e8d2b74b2 100644 --- a/project/plugins.sbt +++ b/project/plugins.sbt @@ -17,7 +17,7 @@ addSbtPlugin("org.foundweekends" % "sbt-bintray" % "0.5.5") // scripted testing libraryDependencies += "org.scala-sbt" %% "scripted-plugin" % sbtVersion.value -libraryDependencies += "com.thesamet.scalapb" %% "compilerplugin" % "0.9.0-M3" +libraryDependencies += "com.thesamet.scalapb" %% "compilerplugin" % "0.9.0-M4" // #java-agent-plugin addSbtPlugin("com.lightbend.sbt" % "sbt-javaagent" % "0.1.5") From 868e1a3c4582fa3ee60936a4a5aa49fbec29b270 Mon Sep 17 00:00:00 2001 From: Arnout Engelen Date: Mon, 27 May 2019 11:07:05 +0200 Subject: [PATCH 7/7] Update versions --- project/Dependencies.scala | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/project/Dependencies.scala b/project/Dependencies.scala index cc4ddd3ed..dbe28acd9 100644 --- a/project/Dependencies.scala +++ b/project/Dependencies.scala @@ -7,18 +7,18 @@ object Dependencies { object Versions { val scala212 = "2.12.8" - val scala213 = "2.13.0-M5" + val scala213 = "2.13.0-RC2" - val akka = "2.5.20" + val akka = "2.5.23" val akkaHttp = "10.1.8" val play = "2.7.0" val grpc = "1.20.0" // checked synced by GrpcVersionSyncCheckPlugin val config = "1.3.3" - val sslConfig = "0.3.7" + val sslConfig = "0.4.0" - val scalaTest = "3.0.7" + val scalaTest = "3.0.8-RC4" val maven = "3.5.4" }