Skip to content
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

sbt-sonatype 3.9.7 does not work with sbt 1.3.x #91

Closed
xuwei-k opened this issue Sep 6, 2019 · 9 comments
Closed

sbt-sonatype 3.9.7 does not work with sbt 1.3.x #91

xuwei-k opened this issue Sep 6, 2019 · 9 comments
Labels

Comments

@xuwei-k
Copy link
Contributor

xuwei-k commented Sep 6, 2019

Maybe sbt 1.2.8 to 1.3.0 break forward binary compatibility? 😢
Should use sbt 1.2.8 when plugin build (if support sbt 1.2)? or await release sbt 1.3.1? /cc @eed3si9n

[error] java.lang.NoSuchMethodError: sbt.package$.singleFileJsonFormatter()Lsjsonnew/JsonFormat;
[error] 	at xerial.sbt.Sonatype$SonatypeKeys.$init$(Sonatype.scala:36)
[error] 	at xerial.sbt.Sonatype$autoImport$.<init>(Sonatype.scala:41)
[error] 	at xerial.sbt.Sonatype$autoImport$.<clinit>(Sonatype.scala)
[error] 	at xerial.sbt.Sonatype$.sonatypeSettings$lzycompute(Sonatype.scala:52)
[error] 	at xerial.sbt.Sonatype$.sonatypeSettings(Sonatype.scala:51)
[error] 	at xerial.sbt.Sonatype$.projectSettings(Sonatype.scala:44)
[error] 	at sbt.internal.Load$.$anonfun$resolveProject$3(Load.scala:1062)
[error] 	at scala.collection.TraversableLike.$anonfun$flatMap$1(TraversableLike.scala:240)
[error] 	at scala.collection.immutable.List.foreach(List.scala:388)
[error] 	at scala.collection.TraversableLike.flatMap(TraversableLike.scala:240)
[error] 	at scala.collection.TraversableLike.flatMap$(TraversableLike.scala:237)
[error] 	at scala.collection.immutable.List.flatMap(List.scala:351)
[error] 	at sbt.internal.Load$.autoPluginSettings$1(Load.scala:1062)
[error] 	at sbt.internal.Load$.expandSettings$1(Load.scala:1081)
[error] 	at sbt.internal.Load$.$anonfun$resolveProject$10(Load.scala:1084)
[error] 	at scala.collection.IndexedSeqOptimized.foldLeft(IndexedSeqOptimized.scala:56)
[error] 	at scala.collection.IndexedSeqOptimized.foldLeft$(IndexedSeqOptimized.scala:64)
[error] 	at scala.collection.mutable.WrappedArray.foldLeft(WrappedArray.scala:37)
[error] 	at scala.collection.TraversableOnce.$div$colon(TraversableOnce.scala:150)
[error] 	at scala.collection.TraversableOnce.$div$colon$(TraversableOnce.scala:150)
[error] 	at scala.collection.AbstractTraversable.$div$colon(Traversable.scala:104)
[error] 	at sbt.internal.Load$.expandSettings$1(Load.scala:1083)
[error] 	at sbt.internal.Load$.$anonfun$resolveProject$1(Load.scala:1097)
[error] 	at sbt.internal.Load$.timed(Load.scala:1395)
[error] 	at sbt.internal.Load$.resolveProject(Load.scala:1051)
[error] 	at sbt.internal.Load$.finalizeProject$1(Load.scala:886)
[error] 	at sbt.internal.Load$.$anonfun$loadTransitive$15(Load.scala:989)
[error] 	at sbt.internal.Load$.timed(Load.scala:1395)
[error] 	at sbt.internal.Load$.loadTransitive(Load.scala:989)
[error] 	at sbt.internal.Load$.loadProjects$1(Load.scala:726)
[error] 	at sbt.internal.Load$.$anonfun$loadUnit$11(Load.scala:729)
[error] 	at sbt.internal.Load$.timed(Load.scala:1395)
[error] 	at sbt.internal.Load$.$anonfun$loadUnit$1(Load.scala:729)
[error] 	at sbt.internal.Load$.timed(Load.scala:1395)
[error] 	at sbt.internal.Load$.loadUnit(Load.scala:688)
[error] 	at sbt.internal.Load$.$anonfun$builtinLoader$4(Load.scala:484)
[error] 	at sbt.internal.BuildLoader$.$anonfun$componentLoader$5(BuildLoader.scala:176)
[error] 	at sbt.internal.BuildLoader.apply(BuildLoader.scala:241)
[error] 	at sbt.internal.Load$.loadURI$1(Load.scala:546)
[error] 	at sbt.internal.Load$.loadAll(Load.scala:562)
[error] 	at sbt.internal.Load$.loadURI(Load.scala:492)
[error] 	at sbt.internal.Load$.load(Load.scala:471)
[error] 	at sbt.internal.Load$.$anonfun$apply$1(Load.scala:251)
[error] 	at sbt.internal.Load$.timed(Load.scala:1395)
[error] 	at sbt.internal.Load$.apply(Load.scala:251)
[error] 	at sbt.internal.Load$.defaultLoad(Load.scala:69)
[error] 	at sbt.BuiltinCommands$.liftedTree1$1(Main.scala:829)
[error] 	at sbt.BuiltinCommands$.doLoadProject(Main.scala:829)
[error] 	at sbt.BuiltinCommands$.$anonfun$loadProjectImpl$2(Main.scala:800)
[error] 	at sbt.Command$.$anonfun$applyEffect$4(Command.scala:142)
[error] 	at sbt.Command$.$anonfun$applyEffect$2(Command.scala:137)
[error] 	at sbt.Command$.process(Command.scala:181)
[error] 	at sbt.MainLoop$.processCommand(MainLoop.scala:151)
[error] 	at sbt.MainLoop$.$anonfun$next$2(MainLoop.scala:139)
[error] 	at sbt.State$$anon$1.runCmd$1(State.scala:246)
[error] 	at sbt.State$$anon$1.process(State.scala:250)
[error] 	at sbt.MainLoop$.$anonfun$next$1(MainLoop.scala:139)
[error] 	at sbt.internal.util.ErrorHandling$.wideConvert(ErrorHandling.scala:16)
[error] 	at sbt.MainLoop$.next(MainLoop.scala:139)
[error] 	at sbt.MainLoop$.run(MainLoop.scala:132)
[error] 	at sbt.MainLoop$.$anonfun$runWithNewLog$1(MainLoop.scala:110)
[error] 	at sbt.io.Using.apply(Using.scala:22)
[error] 	at sbt.MainLoop$.runWithNewLog(MainLoop.scala:104)
[error] 	at sbt.MainLoop$.runAndClearLast(MainLoop.scala:59)
[error] 	at sbt.MainLoop$.runLoggedLoop(MainLoop.scala:44)
[error] 	at sbt.MainLoop$.runLogged(MainLoop.scala:35)
[error] 	at sbt.StandardMain$.runManaged(Main.scala:138)
[error] 	at sbt.xMain.run(Main.scala:89)
[error] 	at xsbt.boot.Launch$$anonfun$run$1.apply(Launch.scala:109)
[error] 	at xsbt.boot.Launch$.withContextLoader(Launch.scala:128)
[error] 	at xsbt.boot.Launch$.run(Launch.scala:109)
[error] 	at xsbt.boot.Launch$$anonfun$apply$1.apply(Launch.scala:35)
[error] 	at xsbt.boot.Launch$.launch(Launch.scala:117)
[error] 	at xsbt.boot.Launch$.apply(Launch.scala:18)
[error] 	at xsbt.boot.Boot$.runImpl(Boot.scala:56)
[error] 	at xsbt.boot.Boot$.main(Boot.scala:18)
[error] 	at xsbt.boot.Boot.main(Boot.scala)
[error] java.lang.NoSuchMethodError: sbt.package$.singleFileJsonFormatter()Lsjsonnew/JsonFormat;
[error] Use 'last' for the full log.
Project loading failed: (r)etry, (q)uit, (l)ast, or (i)gnore? 
@xerial
Copy link
Owner

xerial commented Sep 6, 2019

ok. I'll rollback to sbt 1.2.8 and release a new build for now.

@xerial
Copy link
Owner

xerial commented Sep 6, 2019

Just released sbt-sonatype 3.2 for sbt 1.2.8

@xerial
Copy link
Owner

xerial commented Sep 6, 2019

I've confirmed sbt-sonatpye 3.2 can be used both for sbt 1.2.8 and 1.3.0.

@xuwei-k
Copy link
Contributor Author

xuwei-k commented Sep 6, 2019

sbt/sbt#5049

@mkurz
Copy link

mkurz commented Mar 16, 2021

@xerial The same happens now with 3.9.7 because you upgraded to sbt 1.4.9 in 3b62104 Can you rollback to 1.2.8? Also because that happens from minor release 3.9.6 to 3.9.7...
See playframework/interplay#155

@xerial
Copy link
Owner

xerial commented Mar 16, 2021

@mkurz I had trouble in using sbt 1.2.x probably because of the sunset of Bintray. My counter question would be what is blocking you from using sbt 1.4.x or higher, which already has no such an issue.

A workaround might be releasing sbt-sonatype against sbt-1.1.x series by changing this line:

crossSbtVersions := Vector("1.2.8"),

@xerial xerial reopened this Mar 17, 2021
@xerial xerial changed the title sbt-sonatype 3.1 does not work with sbt 1.2.8 sbt-sonatype 3.9.7 does not work with sbt 1.3.x Mar 17, 2021
@xerial
Copy link
Owner

xerial commented Mar 17, 2021

Changed the ticket title and reopened the issue.

A preferred direction for me is dropping the support for old sbt versions (e.g., 1.2.8) and encourage everybody to migrate to sbt 1.4.x or later. One of the reasons is the old sbt binaries may not be available after bintray is totally shutdown. Another reason is I couldn't compile sbt-sonatype in a new machine, which has no sbt binary in the local cache, if we stick to 1.2.8.

@SethTisue
Copy link

I think dropping 1.2.x is pretty much a no-brainer at this point.

Dropping 1.3.x too would be a bit bolder move, but seems quite reasonable to me.

(And I don't think you should worry about the Bintray thing — both Lightbend and the Scala Center are working on preserving the archives. I can't 100% promise an ideal outcome til it happens, but I suggest optimism here rather than pessimism.)

@xerial
Copy link
Owner

xerial commented Feb 10, 2022

We are now in sbt 1.6.x. I believe it's safe to drop support for Scala sbt 1.3.x now

@xerial xerial added the wontfix label Feb 10, 2022
@xerial xerial closed this as completed May 24, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

4 participants