xerial / sbt-sonatype

A sbt plugin for publishing Scala/Java projects to the Maven central.
Apache License 2.0
335 stars 65 forks source link

sbt-sonatype no longer supports Java 8 #530

Closed armanbilge closed 1 month ago

armanbilge commented 1 month ago

due to the Airframe update

xerial commented 1 month ago

Thanks for identify the cause. As sbt-sonatype doesn't require logback-core, it should be excluded from the transitive dependencies

xerial commented 1 month ago

Released https://github.com/xerial/sbt-sonatype/releases/tag/v3.12.1

xuwei-k commented 1 month ago

does not work 3.12.1

java.lang.NoClassDefFoundError: ch/qos/logback/core/Context
    at wvlet.airframe.http.internal.LogRotationHttpLogger.<init>(LogRotationHttpLogger.scala:39)
    at wvlet.airframe.http.Compat$.$anonfun$defaultHttpClientLoggerFactory$1(Compat.scala:58)
    at wvlet.airframe.http.client.HttpClientConfig.newHttpLogger(HttpClientConfig.scala:178)
    at wvlet.airframe.http.client.SyncClient.$init$(SyncClient.scala:30)
    at wvlet.airframe.http.client.SyncClientImpl.<init>(SyncClient.scala:155)
    at wvlet.airframe.http.client.HttpClientBackend.newSyncClient(HttpClientBackend.scala:28)
    at wvlet.airframe.http.client.HttpClientBackend.newSyncClient$(HttpClientBackend.scala:27)
    at wvlet.airframe.http.client.URLConnectionClientBackend$.newSyncClient(URLConnectionClientBackend.scala:20)
    at wvlet.airframe.http.client.HttpClientConfig.newSyncClient(HttpClientConfig.scala:62)
    at xerial.sbt.sonatype.SonatypeClient.<init>(SonatypeClient.scala:67)
    at xerial.sbt.Sonatype$.withSonatypeService(Sonatype.scala:519)
    at xerial.sbt.Sonatype$.$anonfun$sonatypeBundleRelease$1(Sonatype.scala:241)
xerial commented 1 month ago

I forgot about the logger usage for http clients. Logging might need to be disabled only in Java8

xerial commented 1 month ago

Released a hotfix version https://github.com/xerial/sbt-sonatype/releases/tag/v3.12.2

xerial commented 1 month ago

Note: Java 8 is no longer supported as preparing local build environment for Java 8 is becoming difficult. Consider using Java 17 (LTS) or later