dlsc-software-consulting-gmbh / PreferencesFX

A framework for easily creating a UI for application settings / preferences.
Apache License 2.0
587 stars 68 forks source link

Wrong versions for dependencies? #50

Closed ArvidNy closed 5 years ago

ArvidNy commented 5 years ago

I just tried to add this library to a Gradle project, but the synchronization fails.

Could not find org.controlsfx:controlsfx:9.0.1-SNAPSHOT.
Searched in the following locations:
  - https://jcenter.bintray.com/org/controlsfx/controlsfx/9.0.1-SNAPSHOT/maven-metadata.xml
  - https://jcenter.bintray.com/org/controlsfx/controlsfx/9.0.1-SNAPSHOT/controlsfx-9.0.1-SNAPSHOT.pom
  - https://jcenter.bintray.com/org/controlsfx/controlsfx/9.0.1-SNAPSHOT/controlsfx-9.0.1-SNAPSHOT.jar
  - https://jcenter.bintray.com/org/controlsfx/controlsfx/9.0.1-SNAPSHOT/maven-metadata.xml
  - https://jcenter.bintray.com/org/controlsfx/controlsfx/9.0.1-SNAPSHOT/controlsfx-9.0.1-SNAPSHOT.pom
  - https://jcenter.bintray.com/org/controlsfx/controlsfx/9.0.1-SNAPSHOT/controlsfx-9.0.1-SNAPSHOT.jar
Required by:
    project : > com.dlsc.preferencesfx:preferencesfx-core:11.1.0
Open File

When I was looking at the Maven Repository, it seems like the most recent version is 9.0.0. org.eclipse.fx.ui.controls also requires a higher version number (3.3.0) than the repository has (2.5.0). Or am I just missing something in the setup?

dlemmermann commented 5 years ago

Which Java version are you using? 8, 10, or 11+?

dlemmermann commented 5 years ago

Oh, stupid me. I can tell from your snippet that you are using 11. In this case: the 9.0.1 release of ControlsFX is a snapshot release and the repo for the snapshots is listed in the pom.xml file of the preferences-core module. However, sometimes the snapshot is not available and a build might fail. We all have to wait for a final release of ControlsFX that will support Java 11. It just isn't there, yet.

The repo for org.eclipse.fx.ui.controls is also included in the pom.xml file. So it should be able to download the artifacts from there.

ArvidNy commented 5 years ago

Oh, I didn't notice that the releases are only meant for the corresponding Java version. I'm actually using Java 8, but neither of the other releases worked for me either - they all require the snapshot release. Is Java 8 no longer supported?

dlemmermann commented 5 years ago

PreferencesFX still supports Java 8, of course, everybody is still using that. So if you are using Java 8, then you should work with the "master" branch (if you fork it). If you use a tool like Gradle or Maven then you need to reference version 2.1.0.

dlemmermann commented 5 years ago

The PreferenceFX version for Java 8 does not use the snapshot version of ControlsFX. Only the versions for Java 10 and 11 do that. So you should be fine. If your build continues to search for the 9.0.1-SNAPSHOT release of ControlsFX then you have some other configuration error in your build.

ArvidNy commented 5 years ago

You're right, that's not the error I get with the 2.1.0 release, but rather an error regarding the other dependency I was referring to.

Could not find at.bestsolution.efxclipse.rt:org.eclipse.fx.ui.controls:3.0.0.
Searched in the following locations:
  - https://jcenter.bintray.com/at/bestsolution/efxclipse/rt/org.eclipse.fx.ui.controls/3.0.0/org.eclipse.fx.ui.controls-3.0.0.pom
  - https://jcenter.bintray.com/at/bestsolution/efxclipse/rt/org.eclipse.fx.ui.controls/3.0.0/org.eclipse.fx.ui.controls-3.0.0.jar
  - https://jcenter.bintray.com/at/bestsolution/efxclipse/rt/org.eclipse.fx.ui.controls/3.0.0/org.eclipse.fx.ui.controls-3.0.0.pom
  - https://jcenter.bintray.com/at/bestsolution/efxclipse/rt/org.eclipse.fx.ui.controls/3.0.0/org.eclipse.fx.ui.controls-3.0.0.jar
Required by:
    project : > com.dlsc.preferencesfx:preferencesfx-core:2.1.0
Open File
dlemmermann commented 5 years ago

You need to add the best bestsolution.at repository also:

BestSolution e(fx)clipse releases efxclipse-releases http://maven.bestsolution.at/efxclipse-releases/

On 9 Jan 2019, at 17:03, ArvidNy notifications@github.com wrote:

You're right, that's not the error I get with the 2.1.0 release, but rather an error regarding the other dependency I was referring to.

Could not find at.bestsolution.efxclipse.rt:org.eclipse.fx.ui.controls:3.0.0. Searched in the following locations:

— You are receiving this because you modified the open/close state. Reply to this email directly, view it on GitHub https://github.com/dlemmermann/PreferencesFX/issues/50#issuecomment-452750436, or mute the thread https://github.com/notifications/unsubscribe-auth/AJF7XRmJrEhH8sgTD_0RjdjB7syzAgA3ks5vBhLIgaJpZM4Z3H6H.

ArvidNy commented 5 years ago

That did it, thanks! In case any other Gradle users are here looking, this is what you need to add.

repositories {
    maven {
        url "http://maven.bestsolution.at/efxclipse-releases"
    }
}

Note that it needs to be outside of the buildscript, otherwise it won't work.