@nicholas-boltralik_3634 I investigated this further, and the behavior seems to have existed since 5.2 and earlier.
I'm not totally sure how works Maven, but I'm almost certain you're not supposed to create an artifact with a version that has -SNAPSHOT
in it. Instead, the -SNAPSHOT
seems to be intended for use inside of a <dependency>
only.
if your project depends on a software component that is under active development, you can depend on a snapshot release, and Maven will periodically attempt to download the latest snapshot from a repository when you run a build. Similarly, if the next release of your system is going to have a version “1.8,” your project would have a “1.8-SNAPSHOT” version until it was formally released.
For example , the following dependency would always download the latest 1.8 development JAR of spring:
<dependency>
<groupId>org.springframework</groupId>
<artifactId>spring</artifactId>
<version>1.8-SNAPSHOT”</version>
</dependency>
https://stackoverflow.com/a/45082572
My understanding of how the server logic works, if you request a version with -SNAPSHOT
in it, then the latest version is returned. In other words, -SNAPSHOT
is not a real version, it's just something the server uses t send back the latest version. And since there is no latest version, you get an error.
It seems to be a problem to allow a version called -SNAPSHOT
to be uploaded, because then it's ambiguous. When you ask for -SNAPSHOT
do you want the version named that, or the latest version, etc.
To be honest this is all confusing to me... I'm wondering, why do you create a -SNAPSHOT
version?