-
Notifications
You must be signed in to change notification settings - Fork 53
Running sbt publish
fails due to NoSuchMethodError
#104
Comments
BTW it seems that after downgrading to:
it works fine. |
I also have this issue - also downgraded. |
Same here, trying the downgrade... |
We've found the same issue and tried to resolve it by adding the same dependency override ( Here's the new stack trace when forcing to 3.2.10:
|
The cause of this is dispatch-json4s-native 0.11.3 isn't backwards binary compatible with 0.11.2. In bintry (the library behind sbt-bintray) the dependency on dispatch-json4s-native was:
And then nothing was done about the situation and sbt-bintray 0.4.0 was cut. |
Is the recommended course of action downgrading then? |
Yes. But in the same breath I invite anyone suffering this issue to consider contributing a fix which includes a regression test that represents the reason for the forced downgrade. That way we can avoid future regressions of this issue. |
To fix the underlying issue, I think the solution is to upgrade, not downgrade. According to this issue, they did not have binary compatibility checking turned on at the time: We should try to use the same version of the library in all transitive dependencies (assuming you can get the owners to upgrade ...) Since bintry is using version 3.5.1, I think we should bump all the json4s versions to 3.5.1. As far as regression tests go, I don't see any scripted sbt tests in this repo. It much harder to get that started than to add to it, so I would encourage the owner of this project to help get that started. |
OK - as I have started this issue it is kind of proper for me to at least attempt to fix it. Two PRs with the fix above. It solves the issue but that is definitely not a perfect fix :/ (I wasn't able to reproduce it in unit tests - here are more details: sbt/bintry#28 ) |
By the way @jeffmay - i think that problem with idea of upgrading is that there are some dependencies that use The downgrading change has been merged, we are lacking couple of steps now:
On top of this we obviously need to have PR merged here ( #108 ) and publishing done. This process already contains multiple steps, I am a little worried that adding yet more dependent changes (PRs + publishing process) would make this a very long fix. That said - I 100% agree that, long term, what you say is the best solution. |
OK @dwijnand / @jeffmay I managed to create a test on PR mentiond above ( #108 ) which fully reproduces the issue (with Asking for a friend basically here :) @eed3si9n / @romanowski maybe you guys could help? |
Signed-off-by: Ian Duffy <[email protected]>
I think it's due to conflicting dependency on this lib (
json-native
should be in3.2.10
):My
build.sbt
(I tried to enforce3.2.10
but with no luck...):and my plugins.sbt:
Error is attached below:
The text was updated successfully, but these errors were encountered: