Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Idea, sbt, unable to reparse warning

I've pushed my artifact to oss nexus repo, added it as dependency to another project. Idea keeps me warning:

[warn] Unable to reparse com.github.kondaurovdev#jsonapi_2.11;0.1-SNAPSHOT from sonatype-snapshots, using Fri May 13 17:12:52 MSK 2016 [warn] Choosing sonatype-snapshots for com.github.kondaurovdev#jsonapi_2.11;0.1-SNAPSHOT 

Maybe i pushed artifact somehow in a wrong way? But i did it earlier, everything was ok. How to get rid of these warnings? Or just ignore them?

like image 577
Alexander Kondaurov Avatar asked May 14 '16 10:05

Alexander Kondaurov


2 Answers

I had the same issue.

Did you publish your SNAPSHOT version to your artifactory? If so this might be your problem.

As you know when publishing locally your snapshot version is stored in the .ivy2/local directory. The remote version are stored in the .ivy2/cache directory.

When looking into the .ivy2/cache/{dependency} folder you will see that it has only downloaded the xml and properties file. So just the metadata and no jars. This is the actual reason why it can't be parsed since it's not there.

Since the .ivy2/cache takes precedence over .ivy2/local it won't see your local published version. There are 2 ways to fix this.

  • Update your snapshot version number(recommended)
  • Remove the SNAPSHOT from your artifactory and remove the .ivy2/cache/{dependency} folder on every client that has a local version.

In my opinion the first one is the way to go.

like image 134
Jork Avatar answered Nov 02 '22 15:11

Jork


I had the same issue, and it goes away after I add the follow in my build.sbt:

updateOptions := updateOptions.value.withLatestSnapshots(false)

You can find more detail from https://github.com/sbt/sbt/issues/2650

like image 27
vsftam Avatar answered Nov 02 '22 13:11

vsftam