lightbend-labs / mima

A tool for catching binary incompatibility in Scala
Apache License 2.0
459 stars 71 forks source link

Bintray issue #422

Closed eed3si9n closed 4 years ago

eed3si9n commented 5 years ago

I wanted to link the Bintray package for mima plugin with a prefix so I unlinked it. It turns out that I am unable to link it back, so currently mima plugin is no longer available on sbt plugin releases. I am contacting Bintray..

xuwei-k commented 4 years ago

workaround

resolvers += Resolver.url(
  "typesafe sbt-plugins",
  url("https://dl.bintray.com/typesafe/sbt-plugins")
)(Resolver.ivyStylePatterns)
kubukoz commented 4 years ago

By the way, is there a specific reason for why this plugin isn't published on maven central?

dwijnand commented 4 years ago

The maven repository doesn't really work when you have scala version metadata and sbt version metadata, so the ivy repo is used instead.

Sciss commented 4 years ago

@dwijnand but there are sbt plugins on maven central and no problem. scala and sbt version are encoded in the artifact name (_2.12_1.0) ... so I don't understand what the issue with maven is?

dwijnand commented 4 years ago

You can resolve the plugin, but the fact that the artifactId doesn't match the path means that a POM like https://repo1.maven.org/maven2/org/ensime/sbt-ensime_2.12_1.0/2.6.1/sbt-ensime-2.6.1.pom looks like https://search.maven.org/artifact/org.ensime/sbt-ensime/2.6.1/jar in Maven Central (instead of, for example, https://search.maven.org/artifact/org.scala-lang/scala-library/2.13.1/jar).

This is, of course, just one example. There could be many other things that assume that the two translate (bidirectionally) so it's just treacherous stepping.

eed3si9n commented 4 years ago

To clarify, this isn't an inherent problem with Bintray per se. There are hundreds of plugins that are served by https://repo.scala-sbt.org/scalasbt/sbt-plugin-releases/.

The problem is mostly to do with package linking feature and access control around it. If mima plugin was a package in a https://bintray.com/sbt/sbt-plugin-releases/ repository or in a personal repository it would've just worked like any other plugins. There seems to be something magical about organization repo linking a package to another organization repo.

eed3si9n commented 4 years ago

I've manually uploaded 0.6.1 under a different Bintray package for now:

http://dl.bintray.com/sbt/sbt-plugin-releases/com.typesafe/sbt-mima-plugin/scala_2.12/sbt_1.0/0.6.1/

eed3si9n commented 4 years ago

I've uploaded all previously published versions to https://bintray.com/sbt/sbt-plugin-releases/sbt-mima-plugin-imported2.

dwijnand commented 4 years ago

Are you going to continue to relink the other repo and then unlink that new one?

Or should we switch to publishing to that new repo?

eed3si9n commented 4 years ago

Are you going to continue to relink the other repo and then unlink that new one?

Probably not.

Or should we switch to publishing to that new repo?

If you want multiple people to be able to publish into it, then that would make sense. If so we can rename it to "sbt-mima-plugin".