Skip to content

Commit

Permalink
Drop scala 2.12 + update sbt-tpolecat to 0.5.0 (#900)
Browse files Browse the repository at this point in the history
* Update sbt-tpolecat to 0.4.4

* Formatting

* Drop scala 2.12 and fix unused import errors on scala 3.3

* Formatting

* Drop 2.12

---------

Co-authored-by: mergify[bot] <37929162+mergify[bot]@users.noreply.github.com>
Co-authored-by: svroonland <[email protected]>
Co-authored-by: Steven Vroonland <[email protected]>
  • Loading branch information
4 people authored Nov 25, 2023
1 parent 913a67c commit 7cd8e0f
Show file tree
Hide file tree
Showing 8 changed files with 31 additions and 63 deletions.
12 changes: 1 addition & 11 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ workflows:
- run_with_localstack:
name: test3
image: hseeberger/scala-sbt:17.0.2_1.6.2_3.1.1
sbt_command: ++3.3.0! core/test interopFutures/test
sbt_command: ++3.3.1! core/test interopFutures/test
requires:
- lint
filters:
Expand All @@ -93,21 +93,11 @@ workflows:
filters:
tags:
only: << pipeline.parameters.tag_regex >>
- run_with_localstack:
name: test212
image: hseeberger/scala-sbt:17.0.2_1.6.2_2.12.15
sbt_command: ++2.12.15! interopFutures/compile core/test interopFutures/test Compile/doc
requires:
- lint
filters:
tags:
only: << pipeline.parameters.tag_regex >>
- release:
requires:
- test3
- test213
- test213_dynamic_consumer
- test212
filters:
branches:
only:
Expand Down
49 changes: 15 additions & 34 deletions build.sbt
Original file line number Diff line number Diff line change
Expand Up @@ -65,44 +65,25 @@ lazy val core = (project in file("core"))

lazy val stdSettings: Seq[sbt.Def.SettingsDefinition] = Seq(
Compile / compile / javacOptions ++= Seq("--release", "8"),
Compile / compile / scalacOptions ++= {
// This is for scala.collection.compat._
if (scalaBinaryVersion.value == "2.13")
Seq("-Wconf:cat=unused-imports:silent")
else Seq.empty
} ++ Seq("-release", "8"),
Test / compile / scalacOptions ++= {
// This is for scala.collection.compat._
if (scalaBinaryVersion.value == "2.13")
Seq("-Wconf:cat=unused-imports:silent")
else Seq.empty
},
Compile / doc / scalacOptions ++= {
// This is for scala.collection.compat._
if (scalaBinaryVersion.value == "2.13")
Seq("-Wconf:cat=unused-imports:silent")
else Seq.empty
},
Compile / scalacOptions ~= excludeInferAny,
// Suppresses problems with Scaladoc @throws links
testFrameworks += new TestFramework("zio.test.sbt.ZTestFramework"),
libraryDependencies ++= Seq(
"dev.zio" %% "zio" % zioVersion,
"dev.zio" %% "zio-streams" % zioVersion,
"dev.zio" %% "zio-test" % zioVersion % "test",
"dev.zio" %% "zio-test-sbt" % zioVersion % "test",
"dev.zio" %% "zio-interop-reactivestreams" % "2.0.2",
"dev.zio" %% "zio-logging" % "2.1.15",
"dev.zio" %% "zio-logging-slf4j" % "2.1.15",
"ch.qos.logback" % "logback-classic" % "1.4.11",
"org.scala-lang.modules" %% "scala-collection-compat" % "2.11.0",
"org.hdrhistogram" % "HdrHistogram" % "2.1.12",
"dev.zio" %% "zio-aws-core" % zioAwsVersion,
"dev.zio" %% "zio-aws-kinesis" % zioAwsVersion,
"dev.zio" %% "zio-aws-dynamodb" % zioAwsVersion,
"dev.zio" %% "zio-aws-cloudwatch" % zioAwsVersion,
"dev.zio" %% "zio-aws-netty" % zioAwsVersion,
"javax.xml.bind" % "jaxb-api" % "2.3.1"
"dev.zio" %% "zio" % zioVersion,
"dev.zio" %% "zio-streams" % zioVersion,
"dev.zio" %% "zio-test" % zioVersion % "test",
"dev.zio" %% "zio-test-sbt" % zioVersion % "test",
"dev.zio" %% "zio-interop-reactivestreams" % "2.0.2",
"dev.zio" %% "zio-logging" % "2.1.15",
"dev.zio" %% "zio-logging-slf4j" % "2.1.15",
"ch.qos.logback" % "logback-classic" % "1.4.11",
"org.hdrhistogram" % "HdrHistogram" % "2.1.12",
"dev.zio" %% "zio-aws-core" % zioAwsVersion,
"dev.zio" %% "zio-aws-kinesis" % zioAwsVersion,
"dev.zio" %% "zio-aws-dynamodb" % zioAwsVersion,
"dev.zio" %% "zio-aws-cloudwatch" % zioAwsVersion,
"dev.zio" %% "zio-aws-netty" % zioAwsVersion,
"javax.xml.bind" % "jaxb-api" % "2.3.1"
)
)

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ package nl.vroste.zio.kinesis.client.producer
import io.netty.handler.timeout.ReadTimeoutException
import nl.vroste.zio.kinesis.client.Producer.ProduceResponse
import nl.vroste.zio.kinesis.client._
import nl.vroste.zio.kinesis.client.producer.ProducerLive.ProduceRequest
import nl.vroste.zio.kinesis.client.producer.ProducerLive._
import nl.vroste.zio.kinesis.client.serde.Serializer
import software.amazon.awssdk.core.exception.SdkException
import software.amazon.awssdk.services.kinesis.model.{ KinesisException, ResourceInUseException }
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
package nl.vroste.zio.kinesis.client.zionative

import scala.collection.compat._
import java.time.Instant
import nl.vroste.zio.kinesis.client.zionative.LeaseRepository.Lease
import zio.ZIO
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ import nl.vroste.zio.kinesis.client.zionative.LeaseRepository.{
UnableToClaimLease
}
import nl.vroste.zio.kinesis.client.zionative._
import nl.vroste.zio.kinesis.client.zionative.leasecoordinator.DefaultLeaseCoordinator.State
import nl.vroste.zio.kinesis.client.zionative.leasecoordinator.DefaultLeaseCoordinator._
import nl.vroste.zio.kinesis.client.zionative.leasecoordinator.ZioExtensions.foreachParNUninterrupted_
import software.amazon.awssdk.services.dynamodb.model.ResourceNotFoundException
import zio._
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,6 @@ import zio.stream.ZStream

import java.util.concurrent.TimeoutException
import scala.util.Try
import scala.collection.compat._

// TODO this thing should have a global throttling / backoff
// via a Tap that tries to find the optimal maximal throughput
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,6 @@ import zio.test._
import zio.{ System, _ }
import nl.vroste.zio.kinesis.client.zionative.LeaseRepository.Lease

import scala.collection.compat._
import java.time.Instant
import java.{ util => ju }
import zio.aws.kinesis.model.StreamStatus
Expand Down
26 changes: 13 additions & 13 deletions project/plugins.sbt
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
addSbtPlugin("com.github.sbt" % "sbt-protobuf" % "0.7.2")
addSbtPlugin("org.scalameta" % "sbt-scalafmt" % "2.5.2")
addSbtPlugin("io.github.davidgregory084" % "sbt-tpolecat" % "0.4.2")
addSbtPlugin("com.eed3si9n" % "sbt-assembly" % "2.1.5")
addSbtPlugin("org.scala-js" % "sbt-scalajs" % "1.14.0")
addSbtPlugin("org.portable-scala" % "sbt-scalajs-crossproject" % "1.3.2")
addSbtPlugin("io.shiftleft" % "sbt-ci-release-early" % "2.0.45")
addSbtPlugin("com.47deg" % "sbt-microsites" % "1.3.4")
addSbtPlugin("com.github.sbt" % "sbt-unidoc" % "0.5.0")
addSbtPlugin("com.github.sbt" % "sbt-ci-release" % "1.5.10")
addSbtPlugin("com.github.sbt" % "sbt-pgp" % "2.2.1")
addSbtPlugin("com.dwijnand" % "sbt-dynver" % "4.1.1")
addSbtPlugin("org.xerial.sbt" % "sbt-sonatype" % "3.10.0")
addSbtPlugin("com.github.sbt" % "sbt-protobuf" % "0.7.2")
addSbtPlugin("org.scalameta" % "sbt-scalafmt" % "2.5.2")
addSbtPlugin("org.typelevel" % "sbt-tpolecat" % "0.5.0")
addSbtPlugin("com.eed3si9n" % "sbt-assembly" % "2.1.5")
addSbtPlugin("org.scala-js" % "sbt-scalajs" % "1.14.0")
addSbtPlugin("org.portable-scala" % "sbt-scalajs-crossproject" % "1.3.2")
addSbtPlugin("io.shiftleft" % "sbt-ci-release-early" % "2.0.45")
addSbtPlugin("com.47deg" % "sbt-microsites" % "1.3.4")
addSbtPlugin("com.github.sbt" % "sbt-unidoc" % "0.5.0")
addSbtPlugin("com.github.sbt" % "sbt-ci-release" % "1.5.10")
addSbtPlugin("com.github.sbt" % "sbt-pgp" % "2.2.1")
addSbtPlugin("com.dwijnand" % "sbt-dynver" % "4.1.1")
addSbtPlugin("org.xerial.sbt" % "sbt-sonatype" % "3.10.0")

0 comments on commit 7cd8e0f

Please sign in to comment.