neoforged / AutoRenamingTool

Remapper/renamer of JAR files, with extensibility for other transformations
GNU Lesser General Public License v2.1
3 stars 7 forks source link

Use updated dependencies that are present on central #8

Closed lukebemish closed 7 months ago

lukebemish commented 7 months ago

Requires neoforged/InstallerTools#3 to actually publish InstallerTools to central; as ART is published to central, all its dependencies should be too.

marchermans commented 7 months ago

I would be opposed to this! We have had problems with pulling deps from central in the past.

There is 0 reason to pull from central when the same artifact is on our maven! We publish on central so that other users can consume the artifact without having to use our maven (although personally I put a ❓ behind that reasoning, but that is their decision). However we have our own maven and we should always pull our own artifacts from it.

sciwhiz12 commented 7 months ago

Currently, the fact that we pull ART's dependencies from our Maven repository has caused us to overlook the fact that some of ART's dependencies (that we publish; namely, InstallerTools) aren't available on Maven Central, causing would-be consumers of ART from Maven Central to be unable to do so properly. (See how https://mvnrepository.com/artifact/net.neoforged/AutoRenamingTool/2.0.2 shows the net.neoforged.installertools:cli-utils not being accessible from Central, as opposed to the other dependencies.)

If we remove the use of our Maven repository here, we make it impossible for this situation to happen again: any additional dependency would have to be available on Maven Central, or else Gradle will simply be unable to find the dependency.

Matyrobbrt commented 7 months ago

However we have our own maven and we should always pull our own artifacts from it.

Our maven mirrors central, so we'd always pull artifacts from our maven in user-facing projects (i.e. the installer).
But dependencies of projects on central should use artifacts that are present on central too, otherwise it's useless.

Additionally, the problem of pulling from central was only encountered by the installer, virtually all Gradle projects (and well... maven, basically the entire Java ecosystem) pulls artifacts from central, that's why central exists.

lukebemish commented 7 months ago

Changed back to query neo's maven -- with the understanding that at some point in the no-so-distant future, the neo maven will be split into a central mirror and releases maven which is a superset of the mirror, and this can query only the mirror to prevent this issue happening again.