title: Maven: module-info.java:[6,21] module not found: org.slf4j
body: <p>I'm currently migrating a project to Java 11 (i.e. >= 9) and because JavaFX seems not to work without modules, anymore, I'm currently adding <code>module-info.java</code> files to all sub-projects. But I get the following error:</p>
  
  <pre><code>[INFO] -------------------------------------------------------------
  [ERROR] COMPILATION ERROR : 
  [INFO] -------------------------------------------------------------
  [ERROR] /home/mangu/workspace/cloudstore.2/co.codewizards.java9test.project1/src/main/java/module-info.java:[6,21] module not found: org.slf4j
  [INFO] 1 error
  </code></pre>
  
  <p>I'm running OpenJDK 11.0.3, Maven 3.6.1 (embedded in Eclipse 2019-06) and I definitely have the dependency for the module org.slf4j declared in my pom.xml!</p>
  
  <p>In order to simplify things, I created a little, minimal test-project causing the same error.</p>
  
  <p>Here's the test-project's <code>pom.xml</code>:</p>
  
  <pre><code>&lt;project xmlns="http://maven.apache.org/POM/4.0.0"
      xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
      xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"&gt;
      &lt;modelVersion&gt;4.0.0&lt;/modelVersion&gt;
  
      &lt;groupId&gt;co.codewizards.java9test&lt;/groupId&gt;
      &lt;artifactId&gt;co.codewizards.java9test.project1&lt;/artifactId&gt;
      &lt;version&gt;0.1.0-SNAPSHOT&lt;/version&gt;
  
      &lt;properties&gt;
          &lt;maven.compiler.source&gt;9&lt;/maven.compiler.source&gt;
          &lt;maven.compiler.target&gt;9&lt;/maven.compiler.target&gt;
      &lt;/properties&gt;
  
      &lt;dependencies&gt;
          &lt;dependency&gt;
              &lt;groupId&gt;org.slf4j&lt;/groupId&gt;
              &lt;artifactId&gt;slf4j-api&lt;/artifactId&gt;
              &lt;version&gt;1.8.0-beta4&lt;/version&gt;
          &lt;/dependency&gt;
      &lt;/dependencies&gt;
  
  &lt;/project&gt;
  </code></pre>
  
  <p>I tried both: 1.8.0-beta4 and 2.0.0-alpha0. Eclipse shows me an existing <code>module-info.class</code> in both JARs (i.e. currently inside <code>slf4j-api-1.8.0-beta4.jar</code>).</p>
  
  <p>Here's the <code>module-info.java</code>:</p>
  
  <pre><code>module co.codewizards.java9test.project1 {
  
      requires java.base;
      requires java.se;
  
      requires org.slf4j;
  
  }
  </code></pre>
  
  <p>And here's the output from <code>mvn clean install -Dmaven.test.skip=true -X</code> (but run inside Eclipse): <a href="https://codewizards.co/~mn/tmp/2019-07-31_b3bc43/mvn.log" rel="nofollow noreferrer">mvn.log</a></p>
  
  <p>Any idea what I'm doing wrong?</p>
  
  <p><strong>Update:</strong> I just uploaded the little test project: <a href="https://codewizards.co/~mn/tmp/2019-07-31_b3bc43/co.codewizards.java9test.project1.7z" rel="nofollow noreferrer">co.codewizards.java9test.project1.7z</a></p>