Tristan971 / EasyFXML

A collection of tools and libraries for easier development on the JavaFX platform!
Apache License 2.0
104 stars 5 forks source link

Module not found: slf4j.api #40

Open hubertstruminski opened 4 years ago

hubertstruminski commented 4 years ago

Hi,

After I added easyfxml dependency and I used some EasyFXML classes inside my project when I try build project I get error "module not found: slf4j.api".

I have the following dependencies for slf4j:

`

org.slf4j slf4j-api 1.7.30
    <dependency>
        <groupId>org.slf4j</groupId>
        <artifactId>slf4j-simple</artifactId>
        <version>1.7.30</version>
    </dependency>

`

In the module-info.java I have the following lines:

requires java.base; requires java.se; requires org.slf4j; requires org.slf4j.simple;

I can not find any example for resolve this problem in the internet. I tried change versions but it nothing helped.

Error: Error:java: module not found: slf4j.api

Is someone here who knows solution for this problem ?

Tristan971 commented 4 years ago

Hi,

After looking around, it seems that SLF4J went from the automatic module name of slf4j.api to an explicit module name of org.slf4j. And indeed this causes

https://github.com/Tristan971/EasyFXML/blob/master/easyfxml/src/main/java/module-info.java#L24

to require something that existed with SLF4J 1.7.26 but not anymore in 1.7.30

I'll make a fix version, thanks for the report

Tristan971 commented 4 years ago

In the meantime (as I'll update other dependencies and refresh things a bit), using slf4j 1.7.26 should work. see https://jira.qos.ch/browse/SLF4J-420

Tristan971 commented 4 years ago

Thanks for closing but I'll keep it open until I have it fully fixed