diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 562e3c51..25cdf702 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -37,6 +37,9 @@ jobs: runs-on: ${{ matrix.os }} timeout-minutes: 60 steps: + - name: Install sbt + uses: sbt/setup-sbt@v1 + - name: Checkout current branch (full) uses: actions/checkout@v4 with: @@ -119,6 +122,9 @@ jobs: java: [temurin@11] runs-on: ${{ matrix.os }} steps: + - name: Install sbt + uses: sbt/setup-sbt@v1 + - name: Checkout current branch (full) uses: actions/checkout@v4 with: @@ -196,13 +202,16 @@ jobs: dependency-submission: name: Submit Dependencies - if: github.event_name != 'pull_request' + if: github.event.repository.fork == false && github.event_name != 'pull_request' strategy: matrix: os: [ubuntu-latest] java: [temurin@11] runs-on: ${{ matrix.os }} steps: + - name: Install sbt + uses: sbt/setup-sbt@v1 + - name: Checkout current branch (full) uses: actions/checkout@v4 with: @@ -248,6 +257,9 @@ jobs: java: [temurin@11] runs-on: ${{ matrix.os }} steps: + - name: Install sbt + uses: sbt/setup-sbt@v1 + - name: Checkout current branch (full) uses: actions/checkout@v4 with: @@ -284,7 +296,7 @@ jobs: - name: Publish site if: github.event_name != 'pull_request' && github.ref == 'refs/heads/main' - uses: peaceiris/actions-gh-pages@v3.9.3 + uses: peaceiris/actions-gh-pages@v4.0.0 with: github_token: ${{ secrets.GITHUB_TOKEN }} publish_dir: site/target/docs/site diff --git a/.scalafmt.conf b/.scalafmt.conf index d5e30326..4943dbe8 100644 --- a/.scalafmt.conf +++ b/.scalafmt.conf @@ -1,4 +1,4 @@ -version=3.8.0 +version=3.8.3 runner.dialect = scala213 style = default diff --git a/build.sbt b/build.sbt index 9bad8f19..5f878b6c 100644 --- a/build.sbt +++ b/build.sbt @@ -34,18 +34,18 @@ ThisBuild / mergifyStewardConfig := Some( ThisBuild / mergifyRequiredJobs += "site" ThisBuild / mergifyLabelPaths += "docs" -> file("docs") -val catsV = "2.10.0" -val catsEffectV = "3.5.3" -val fs2V = "3.9.4" -val scodecV = "1.1.38" -val http4sV = "1.0.0-M40" +val catsV = "2.12.0" +val catsEffectV = "3.5.5" +val fs2V = "3.11.0" +val scodecV = "1.2.1" +val http4sV = "1.0.0-M43" val log4catsV = "2.7.0" val reactiveStreamsV = "1.0.4" -val vaultV = "3.5.0" -val caseInsensitiveV = "1.4.0" +val vaultV = "3.6.0" +val caseInsensitiveV = "1.4.2" -val munitV = "1.0.0-M11" -val munitCatsEffectV = "2.0.0-M4" +val munitV = "1.0.2" +val munitCatsEffectV = "2.0.0" val emberServer = Seq( "org.http4s" %% "http4s-ember-server" % http4sV, @@ -70,8 +70,8 @@ val coreDeps = Seq( "org.typelevel" %% "munit-cats-effect" % munitCatsEffectV )).map(_ % Test) -val scala213 = "2.13.12" -ThisBuild / crossScalaVersions := Seq(scala213, "3.3.3") +val scala213 = "2.13.15" +ThisBuild / crossScalaVersions := Seq(scala213, "3.3.4") ThisBuild / scalaVersion := scala213 ThisBuild / tlBaseVersion := "1.0" ThisBuild / startYear := Some(2019) diff --git a/core/src/main/scala/org/http4s/jdkhttpclient/JdkWSClient.scala b/core/src/main/scala/org/http4s/jdkhttpclient/JdkWSClient.scala index 55851abb..f8d128e1 100644 --- a/core/src/main/scala/org/http4s/jdkhttpclient/JdkWSClient.scala +++ b/core/src/main/scala/org/http4s/jdkhttpclient/JdkWSClient.scala @@ -122,7 +122,7 @@ object JdkWSClient { errs <- Stream .repeatEval(queue.tryTake) .unNoneTerminate - .collect { case Left(e) => e } + .collect { case Left(t) => t } .compile .toList _ <- F.raiseError[Unit](CompositeFailure.fromList(errs) match { diff --git a/core/src/test/scala/org/http4s/jdkhttpclient/BodyLeakExample.scala b/core/src/test/scala/org/http4s/jdkhttpclient/BodyLeakExample.scala index bc8b6e7d..584f5734 100644 --- a/core/src/test/scala/org/http4s/jdkhttpclient/BodyLeakExample.scala +++ b/core/src/test/scala/org/http4s/jdkhttpclient/BodyLeakExample.scala @@ -31,7 +31,7 @@ import org.typelevel.log4cats.noop.NoOpFactory // Run e.g. with `bloop run core-test --args -J-Xmx200M` object BodyLeakExample extends IOApp { - implicit val loggerFactor: LoggerFactory[IO] = NoOpFactory[IO] + implicit val loggerFactory: LoggerFactory[IO] = NoOpFactory[IO] val app: HttpApp[IO] = Kleisli((_: Request[IO]) => IO.pure(Response[IO]().withEntity("Hello, HTTP"))) diff --git a/core/src/test/scala/org/http4s/jdkhttpclient/CompletableFutureTerminationTest.scala b/core/src/test/scala/org/http4s/jdkhttpclient/CompletableFutureTerminationTest.scala index ca4cb066..18ae0afa 100644 --- a/core/src/test/scala/org/http4s/jdkhttpclient/CompletableFutureTerminationTest.scala +++ b/core/src/test/scala/org/http4s/jdkhttpclient/CompletableFutureTerminationTest.scala @@ -40,7 +40,7 @@ import scala.concurrent.duration._ final class CompletableFutureTerminationTest extends CatsEffectSuite { import CompletableFutureTerminationTest._ - implicit val loggerFactor: LoggerFactory[IO] = NoOpFactory[IO] + implicit val loggerFactory: LoggerFactory[IO] = NoOpFactory[IO] private val duration: FiniteDuration = FiniteDuration(50L, TimeUnit.MILLISECONDS) diff --git a/core/src/test/scala/org/http4s/jdkhttpclient/JdkWSClientSpec.scala b/core/src/test/scala/org/http4s/jdkhttpclient/JdkWSClientSpec.scala index 3d22cb7d..0e49af62 100644 --- a/core/src/test/scala/org/http4s/jdkhttpclient/JdkWSClientSpec.scala +++ b/core/src/test/scala/org/http4s/jdkhttpclient/JdkWSClientSpec.scala @@ -37,7 +37,7 @@ import scala.concurrent.duration._ class JdkWSClientSpec extends CatsEffectSuite { - implicit val loggerFactor: LoggerFactory[IO] = NoOpFactory[IO] + implicit val loggerFactory: LoggerFactory[IO] = NoOpFactory[IO] val webSocket: IOFixture[WSClient[IO]] = ResourceSuiteLocalFixture("webSocket", Resource.eval(JdkWSClient.simple[IO])) diff --git a/docs/README.md b/docs/README.md index 34e74b3a..721bcf2e 100644 --- a/docs/README.md +++ b/docs/README.md @@ -192,7 +192,7 @@ import com.comcast.ip4s._ import org.typelevel.log4cats.LoggerFactory import org.typelevel.log4cats.noop.NoOpFactory -implicit val loggerFactor: LoggerFactory[IO] = NoOpFactory[IO] +implicit val loggerFactory: LoggerFactory[IO] = NoOpFactory[IO] val echoServer = EmberServerBuilder.default[IO] .withPort(port"0") diff --git a/flake.lock b/flake.lock index 700d3efd..51a70130 100644 --- a/flake.lock +++ b/flake.lock @@ -3,14 +3,17 @@ "devshell": { "inputs": { "flake-utils": "flake-utils", - "nixpkgs": "nixpkgs" + "nixpkgs": [ + "typelevel-nix", + "nixpkgs" + ] }, "locked": { - "lastModified": 1705332421, - "narHash": "sha256-USpGLPme1IuqG78JNqSaRabilwkCyHmVWY0M9vYyqEA=", + "lastModified": 1713532798, + "narHash": "sha256-wtBhsdMJA3Wa32Wtm1eeo84GejtI43pMrFrmwLXrsEc=", "owner": "numtide", "repo": "devshell", - "rev": "83cb93d6d063ad290beee669f4badf9914cc16ec", + "rev": "12e914740a25ea1891ec619bb53cf5e6ca922e40", "type": "github" }, "original": { @@ -42,11 +45,11 @@ "systems": "systems_2" }, "locked": { - "lastModified": 1705309234, - "narHash": "sha256-uNRRNRKmJyCRC/8y1RqBkqWBLM034y4qN7EprSdmgyA=", + "lastModified": 1710146030, + "narHash": "sha256-SZ5L6eA7HJ/nmkzGG7/ISclqe6oZdOZTNoesiInkXPQ=", "owner": "numtide", "repo": "flake-utils", - "rev": "1ef2e671c3b0c19053962c07dbda38332dcebf26", + "rev": "b1d9ab70662946ef0850d488da1c9019f3a9752a", "type": "github" }, "original": { @@ -57,27 +60,11 @@ }, "nixpkgs": { "locked": { - "lastModified": 1704161960, - "narHash": "sha256-QGua89Pmq+FBAro8NriTuoO/wNaUtugt29/qqA8zeeM=", - "owner": "NixOS", - "repo": "nixpkgs", - "rev": "63143ac2c9186be6d9da6035fa22620018c85932", - "type": "github" - }, - "original": { - "owner": "NixOS", - "ref": "nixpkgs-unstable", - "repo": "nixpkgs", - "type": "github" - } - }, - "nixpkgs_2": { - "locked": { - "lastModified": 1706367331, - "narHash": "sha256-AqgkGHRrI6h/8FWuVbnkfFmXr4Bqsr4fV23aISqj/xg=", + "lastModified": 1716715802, + "narHash": "sha256-usk0vE7VlxPX8jOavrtpOqphdfqEQpf9lgedlY/r66c=", "owner": "nixos", "repo": "nixpkgs", - "rev": "160b762eda6d139ac10ae081f8f78d640dd523eb", + "rev": "e2dd4e18cc1c7314e24154331bae07df76eb582f", "type": "github" }, "original": { @@ -134,14 +121,14 @@ "inputs": { "devshell": "devshell", "flake-utils": "flake-utils_2", - "nixpkgs": "nixpkgs_2" + "nixpkgs": "nixpkgs" }, "locked": { - "lastModified": 1706547644, - "narHash": "sha256-NGQ34yoAKu5jykVJtQ8dWsEh2MF88SpWXkT/ldhvzn0=", + "lastModified": 1716858680, + "narHash": "sha256-HYj9yoYOogKvC4lFx20mdrIkn0UBbYxkrp/1cycNrFM=", "owner": "typelevel", "repo": "typelevel-nix", - "rev": "2bbdddbc81a9da0052a22d7d8ebd17b88cd55a8f", + "rev": "e494632f444ab0a45c7294e6231a0e7e13053e64", "type": "github" }, "original": { diff --git a/project/build.properties b/project/build.properties index 04267b14..db1723b0 100644 --- a/project/build.properties +++ b/project/build.properties @@ -1 +1 @@ -sbt.version=1.9.9 +sbt.version=1.10.5 diff --git a/project/plugins.sbt b/project/plugins.sbt index 8e251cb7..8707c196 100644 --- a/project/plugins.sbt +++ b/project/plugins.sbt @@ -1,2 +1,2 @@ -addSbtPlugin("org.http4s" % "sbt-http4s-org" % "0.16.3") -addSbtPlugin("org.typelevel" % "sbt-typelevel-mergify" % "0.6.7") +addSbtPlugin("org.http4s" % "sbt-http4s-org" % "0.17.5") +addSbtPlugin("org.typelevel" % "sbt-typelevel-mergify" % "0.7.4")