title: IntelliJ, Maven, Flexmojos - Failed to generate Flex compiler configuration file
body: <p>I'm running a multi-project build in IntelliJ setup with Flexmojos.</p>
  
  <p>All of the flex modules have a common parent pom file which is downloaded from Artifactory. This dependency seems to be resolved properly but when I hit "Reimport All Maven Projects", or do changes to any child pom file, I get an error </p>
  
  <pre><code>Flexmojos Project Import
  **Failed to generate Flex compiler configuration file.**
  The pipe has been ended
  
  Flexmojos Project Import
  **Failed to generate Flex compiler configuration file.** 
  exit code: 1
  </code></pre>
  
  <p>Globals (using maven 'defines' tag) defined in the parent pom are not visible in any child project and if I go into "Project Structure" there is </p>
  
  <pre><code>"Build configurations '[child artifactId]': additional compiler configuration file not found: [absolute path]"
  </code></pre>
  
  <p>, which is a symptom of the missing configuration files.</p>
  
  <p>I think it is a settings (IntelliJ? Maven? Java?) issue because my colleague has the same code from SVN and does not have the same issue.</p>
  
  <p>Any clues as to where to start looking?</p>
  
  <p>EDIT:</p>
  
  <p>Excerpt from idea.log</p>
  
  <pre><code>2013-08-13 16:35:34,213 [1978178]   INFO -      #org.jetbrains.idea.maven - Generating flex configs pathToBundledJar: C:\Program Files (x86)\JetBrains\IntelliJ IDEA 12.1.4\plugins\flex\lib\flexmojos-flex-configs-generator-server.jar 
  2013-08-13 16:35:34,214 [1978179]   INFO -      #org.jetbrains.idea.maven - Generate Flex Configs Task:"c:\program files\java\jdk1.7.0_25\jre\bin\java" -Dfile.encoding=windows-1252 -classpath "C:\Program Files (x86)\JetBrains\IntelliJ IDEA 12.1.4\plugins\flex\lib\flexmojos-flex-configs-generator-server.jar;C:\Program Files (x86)\maven-3.1.0\apache-maven-3.1.0\lib\aether-api-0.9.0.M2.jar;C:\Program Files (x86)\maven-3.1.0\apache-maven-3.1.0\lib\aether-connector-wagon-0.9.0.M2.jar;C:\Program Files (x86)\maven-3.1.0\apache-maven-3.1.0\lib\aether-impl-0.9.0.M2.jar;C:\Program Files (x86)\maven-3.1.0\apache-maven-3.1.0\lib\aether-spi-0.9.0.M2.jar;C:\Program Files (x86)\maven-3.1.0\apache-maven-3.1.0\lib\aether-util-0.9.0.M2.jar;C:\Program Files (x86)\maven-3.1.0\apache-maven-3.1.0\lib\aopalliance-1.0.jar;C:\Program Files (x86)\maven-3.1.0\apache-maven-3.1.0\lib\asm-3.3.1.jar;C:\Program Files (x86)\maven-3.1.0\apache-maven-3.1.0\lib\cdi-api-1.0.jar;C:\Program Files (x86)\maven-3.1.0\apache-maven-3.1.0\lib\guava-11.0.2.jar;C:\Program Files (x86)\maven-3.1.0\apache-maven-3.1.0\lib\javax.inject-1.jar;C:\Program Files (x86)\maven-3.1.0\apache-maven-3.1.0\lib\jsr250-api-1.0.jar;C:\Program Files (x86)\maven-3.1.0\apache-maven-3.1.0\lib\jsr305-1.3.9.jar;C:\Program Files (x86)\maven-3.1.0\apache-maven-3.1.0\lib\maven-aether-provider-3.1.0.jar;C:\Program Files (x86)\maven-3.1.0\apache-maven-3.1.0\lib\maven-artifact-3.1.0.jar;C:\Program Files (x86)\maven-3.1.0\apache-maven-3.1.0\lib\maven-compat-3.1.0.jar;C:\Program Files (x86)\maven-3.1.0\apache-maven-3.1.0\lib\maven-core-3.1.0.jar;C:\Program Files (x86)\maven-3.1.0\apache-maven-3.1.0\lib\maven-model-3.1.0.jar;C:\Program Files (x86)\maven-3.1.0\apache-maven-3.1.0\lib\maven-model-builder-3.1.0.jar;C:\Program Files (x86)\maven-3.1.0\apache-maven-3.1.0\lib\maven-plugin-api-3.1.0.jar;C:\Program Files (x86)\maven-3.1.0\apache-maven-3.1.0\lib\maven-repository-metadata-3.1.0.jar;C:\Program Files (x86)\maven-3.1.0\apache-maven-3.1.0\lib\maven-settings-3.1.0.jar;C:\Program Files (x86)\maven-3.1.0\apache-maven-3.1.0\lib\maven-settings-builder-3.1.0.jar;C:\Program Files (x86)\maven-3.1.0\apache-maven-3.1.0\lib\org.eclipse.sisu.inject-0.0.0.M2a.jar;C:\Program Files (x86)\maven-3.1.0\apache-maven-3.1.0\lib\org.eclipse.sisu.plexus-0.0.0.M2a.jar;C:\Program Files (x86)\maven-3.1.0\apache-maven-3.1.0\lib\plexus-cipher-1.7.jar;C:\Program Files (x86)\maven-3.1.0\apache-maven-3.1.0\lib\plexus-component-annotations-1.5.5.jar;C:\Program Files (x86)\maven-3.1.0\apache-maven-3.1.0\lib\plexus-interpolation-1.16.jar;C:\Program Files (x86)\maven-3.1.0\apache-maven-3.1.0\lib\plexus-sec-dispatcher-1.3.jar;C:\Program Files (x86)\maven-3.1.0\apache-maven-3.1.0\lib\plexus-utils-3.0.10.jar;C:\Program Files (x86)\maven-3.1.0\apache-maven-3.1.0\lib\sisu-guice-3.1.3-no_aop.jar;C:\Program Files (x86)\maven-3.1.0\apache-maven-3.1.0\lib\slf4j-api-1.7.4.jar;C:\Program Files (x86)\maven-3.1.0\apache-maven-3.1.0\lib\slf4j-simple-1.7.4.jar;C:\Program Files (x86)\maven-3.1.0\apache-maven-3.1.0\lib\wagon-file-2.4.jar;C:\Program Files (x86)\maven-3.1.0\apache-maven-3.1.0\lib\wagon-http-2.4-shaded.jar;C:\Program Files (x86)\maven-3.1.0\apache-maven-3.1.0\lib\wagon-provider-api-2.4.jar;C:\Program Files (x86)\maven-3.1.0\apache-maven-3.1.0\boot\plexus-classworlds-2.4.2.jar" com.intellij.flex.maven.GeneratorServer "C:\Program Files (x86)\maven-3.1.0\apache-maven-3.1.0\conf\settings.xml" " " C:\Users\XXXXXXXX\.m2\repository f D:/XXXXXXXXXXX/trunk/.idea/flexmojos 
  2013-08-13 16:35:34,534 [1978499]  ERROR -      #org.jetbrains.idea.maven - The pipe has been ended 
  java.io.IOException: The pipe has been ended
      at java.io.FileOutputStream.writeBytes(Native Method)
      at java.io.FileOutputStream.write(FileOutputStream.java:318)
      at java.io.BufferedOutputStream.flushBuffer(BufferedOutputStream.java:82)
      at java.io.BufferedOutputStream.flush(BufferedOutputStream.java:140)
      at java.io.BufferedOutputStream.flush(BufferedOutputStream.java:141)
      at java.io.DataOutputStream.flush(DataOutputStream.java:123)
      at java.io.ObjectOutputStream$BlockDataOutputStream.flush(ObjectOutputStream.java:1816)
      at java.io.ObjectOutputStream.flush(ObjectOutputStream.java:716)
      at com.intellij.javascript.flex.maven.Flexmojos4GenerateConfigTask.writeWorkspaceMap(Flexmojos4GenerateConfigTask.java:379)
      at com.intellij.javascript.flex.maven.Flexmojos4GenerateConfigTask.runGeneratorServer(Flexmojos4GenerateConfigTask.java:198)
      at com.intellij.javascript.flex.maven.Flexmojos4GenerateConfigTask.perform(Flexmojos4GenerateConfigTask.java:80)
      at org.jetbrains.idea.maven.project.MavenProjectsProcessor.doProcessPendingTasks(MavenProjectsProcessor.java:131)
      at org.jetbrains.idea.maven.project.MavenProjectsProcessor.access$100(MavenProjectsProcessor.java:28)
      at org.jetbrains.idea.maven.project.MavenProjectsProcessor$2.run(MavenProjectsProcessor.java:107)
      at org.jetbrains.idea.maven.utils.MavenUtil$9.run(MavenUtil.java:433)
      at com.intellij.openapi.application.impl.ApplicationImpl$8.run(ApplicationImpl.java:454)
      at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:471)
      at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:334)
      at java.util.concurrent.FutureTask.run(FutureTask.java:166)
      at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
      at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
      at java.lang.Thread.run(Thread.java:724)
      at com.intellij.openapi.application.impl.ApplicationImpl$1$1.run(ApplicationImpl.java:152)
  2013-08-13 16:35:34,536 [1978501]  ERROR -      #org.jetbrains.idea.maven - IntelliJ IDEA 12.1.4  Build #IU-129.713 
  2013-08-13 16:35:34,536 [1978501]  ERROR -      #org.jetbrains.idea.maven - JDK: 1.7.0_25 
  2013-08-13 16:35:34,536 [1978501]  ERROR -      #org.jetbrains.idea.maven - VM: Java HotSpot(TM) 64-Bit Server VM 
  2013-08-13 16:35:34,536 [1978501]  ERROR -      #org.jetbrains.idea.maven - Vendor: Oracle Corporation 
  2013-08-13 16:35:34,536 [1978501]  ERROR -      #org.jetbrains.idea.maven - OS: Windows 7 
  2013-08-13 16:35:34,536 [1978501]  ERROR -      #org.jetbrains.idea.maven - Last Action: SaveAll 
  2013-08-13 16:35:34,537 [1978502]   WARN -      #org.jetbrains.idea.maven - Generating flex configs exited with exit code 1 
  2013-08-13 16:35:34,537 [1978502]   INFO -      #org.jetbrains.idea.maven - Generating flex configs out:
  java.lang.NoClassDefFoundError: org/sonatype/aether/RepositorySystemSession
  
      at java.lang.Class.getDeclaredMethods0(Native Method)
  
      at java.lang.Class.privateGetDeclaredMethods(Class.java:2521)
  
      at java.lang.Class.getMethod0(Class.java:2764)
  
      at java.lang.Class.getMethod(Class.java:1653)
  
      at sun.launcher.LauncherHelper.getMainMethod(LauncherHelper.java:494)
  
      at sun.launcher.LauncherHelper.checkAndLoadMain(LauncherHelper.java:486)
  
  Caused by: java.lang.ClassNotFoundException: org.sonatype.aether.RepositorySystemSession
  
      at java.net.URLClassLoader$1.run(URLClassLoader.java:366)
  
      at java.net.URLClassLoader$1.run(URLClassLoader.java:355)
  
      at java.security.AccessController.doPrivileged(Native Method)
  
      at java.net.URLClassLoader.findClass(URLClassLoader.java:354)
  
      at java.lang.ClassLoader.loadClass(ClassLoader.java:424)
  
      at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:308)
  
      at java.lang.ClassLoader.loadClass(ClassLoader.java:357)
  
      ... 6 more
  
  Exception in thread "main"  
  2013-08-13 16:35:35,036 [1979001]   INFO -      #org.jetbrains.idea.maven - Generating flex configs took 824 ms: 0 min 0sec 
  </code></pre>
  
  <p>EDIT:
  A typical child pom file has no build tag, it is supposed to inherit it from the base pom, they still have packaging 'swc' though.</p>
  
  <p>Base pom has:</p>
  
  <pre><code>&lt;flexmojos.version&gt;4.2-beta&lt;/flexmojos.version&gt;
  &lt;playerglobal.version&gt;11.0&lt;/playerglobal.version&gt;
  &lt;flexunit.version&gt;4.1.0.8&lt;/flexunit.version&gt;
  &lt;flex.sdk.version&gt;4.5.1.21328&lt;/flex.sdk.version&gt;
  &lt;flexpmd.version&gt;1.2&lt;/flexpmd.version&gt;
  </code></pre>
  
  <p>The full base pom:</p>
  
  <pre><code>&lt;?xml version="1.0" encoding="UTF-8"?&gt;
  &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/maven-v4_0_0.xsd"&gt;
      &lt;modelVersion&gt;4.0.0&lt;/modelVersion&gt;
  
      &lt;groupId&gt;com.XXXXXX&lt;/groupId&gt;
      &lt;artifactId&gt;config&lt;/artifactId&gt;
      &lt;version&gt;1.1.3-SNAPSHOT&lt;/version&gt;
      &lt;packaging&gt;pom&lt;/packaging&gt;
  
      &lt;name&gt;Toolbox - Config&lt;/name&gt;
  
      &lt;properties&gt;
  
          &lt;build.debug&gt;false&lt;/build.debug&gt;
          &lt;swf.version&gt;13&lt;/swf.version&gt;
  
          &lt;flex.flashPlayer.command&gt;C:\FlashPlayer.exe&lt;/flex.flashPlayer.command&gt;
          &lt;flexmojos.version&gt;4.2-beta&lt;/flexmojos.version&gt;
          &lt;playerglobal.version&gt;11.0&lt;/playerglobal.version&gt;
          &lt;flexunit.version&gt;4.1.0.8&lt;/flexunit.version&gt;
          &lt;flex.sdk.version&gt;4.5.1.21328&lt;/flex.sdk.version&gt;
          &lt;flexpmd.version&gt;1.2&lt;/flexpmd.version&gt;
  
          &lt;path.source&gt;src&lt;/path.source&gt;
          &lt;project.build.sourceEncoding&gt;UTF-8&lt;/project.build.sourceEncoding&gt;
      &lt;/properties&gt;
  
      &lt;scm&gt;
          &lt;connection&gt;scm:svn:XXXXXX&lt;/connection&gt;
      &lt;/scm&gt;
  
      &lt;build&gt;
          &lt;sourceDirectory&gt;${path.source}&lt;/sourceDirectory&gt;
          &lt;plugins&gt;
              &lt;plugin&gt;
                  &lt;groupId&gt;org.sonatype.flexmojos&lt;/groupId&gt;
                  &lt;artifactId&gt;flexmojos-maven-plugin&lt;/artifactId&gt;
                  &lt;version&gt;${flexmojos.version}&lt;/version&gt;
                  &lt;extensions&gt;true&lt;/extensions&gt;
                  &lt;configuration&gt;
                      &lt;swfVersion&gt;${swf.version}&lt;/swfVersion&gt;
                      &lt;compilerWarnings&gt;
                          &lt;warn-no-constructor&gt;false&lt;/warn-no-constructor&gt;
                      &lt;/compilerWarnings&gt;
                      &lt;dumpConfigAttach&gt;false&lt;/dumpConfigAttach&gt;
                      &lt;verboseStacktraces&gt;${build.debug}&lt;/verboseStacktraces&gt;
                      &lt;debug&gt;${build.debug}&lt;/debug&gt;
                      &lt;!--&lt;coverage&gt;${build.debug}&lt;/coverage&gt;--&gt;
                      &lt;defines&gt;
                          &lt;property&gt;
                              &lt;name&gt;CONFIG::debug&lt;/name&gt;
                              &lt;value&gt;${build.debug}&lt;/value&gt;
                          &lt;/property&gt;
                      &lt;/defines&gt;
                      &lt;storepass&gt;true&lt;/storepass&gt;
                  &lt;/configuration&gt;
                  &lt;dependencies&gt;
                      &lt;dependency&gt;
                          &lt;groupId&gt;com.adobe.flex&lt;/groupId&gt;
                          &lt;artifactId&gt;compiler&lt;/artifactId&gt;
                          &lt;version&gt;${flex.sdk.version}&lt;/version&gt;
                          &lt;type&gt;pom&lt;/type&gt;
                      &lt;/dependency&gt;
                  &lt;/dependencies&gt;
              &lt;/plugin&gt;
              &lt;plugin&gt;
                  &lt;groupId&gt;com.googlecode.apparat&lt;/groupId&gt;
                  &lt;artifactId&gt;apparat-maven-plugin&lt;/artifactId&gt;
                  &lt;version&gt;1.0-RC9&lt;/version&gt;
                  &lt;executions&gt;
                      &lt;execution&gt;
                          &lt;id&gt;tdsi-package&lt;/id&gt;
                          &lt;goals&gt;
                              &lt;goal&gt;tdsi&lt;/goal&gt;
                          &lt;/goals&gt;
                      &lt;/execution&gt;
                  &lt;/executions&gt;
                  &lt;configuration&gt;
                      &lt;alchemyExpansion&gt;false&lt;/alchemyExpansion&gt;
                      &lt;inlineExpansion&gt;true&lt;/inlineExpansion&gt;
                      &lt;macroExpansion&gt;true&lt;/macroExpansion&gt;
                  &lt;/configuration&gt;
              &lt;/plugin&gt;
              &lt;plugin&gt;
                  &lt;groupId&gt;com.adobe.ac&lt;/groupId&gt;
                  &lt;artifactId&gt;flex-pmd-maven-plugin&lt;/artifactId&gt;
                  &lt;version&gt;${flexpmd.version}&lt;/version&gt;
                  &lt;configuration&gt;
                      &lt;ruleSet&gt;../../pmd-ruleset.xml&lt;/ruleSet&gt;
                  &lt;/configuration&gt;
                  &lt;executions&gt;
                      &lt;execution&gt;
                          &lt;phase&gt;site&lt;/phase&gt;
                          &lt;goals&gt;
                              &lt;goal&gt;check&lt;/goal&gt;
                          &lt;/goals&gt;
                      &lt;/execution&gt;
                  &lt;/executions&gt;
              &lt;/plugin&gt;
              &lt;plugin&gt;
                  &lt;groupId&gt;com.adobe.ac&lt;/groupId&gt;
                  &lt;artifactId&gt;flex-pmd-cpd-maven-plugin&lt;/artifactId&gt;
                  &lt;version&gt;${flexpmd.version}&lt;/version&gt;
                  &lt;configuration&gt;
                      &lt;minimumTokenCount&gt;50&lt;/minimumTokenCount&gt;
                  &lt;/configuration&gt;
                  &lt;executions&gt;
                      &lt;execution&gt;
                          &lt;phase&gt;site&lt;/phase&gt;
                          &lt;goals&gt;
                              &lt;goal&gt;check&lt;/goal&gt;
                          &lt;/goals&gt;
                      &lt;/execution&gt;
                  &lt;/executions&gt;
              &lt;/plugin&gt;
              &lt;plugin&gt;
                  &lt;groupId&gt;com.adobe.ac&lt;/groupId&gt;
                  &lt;artifactId&gt;flex-pmd-metrics-maven-plugin&lt;/artifactId&gt;
                  &lt;version&gt;${flexpmd.version}&lt;/version&gt;
                  &lt;executions&gt;
                      &lt;execution&gt;
                          &lt;phase&gt;site&lt;/phase&gt;
                          &lt;goals&gt;
                              &lt;goal&gt;check&lt;/goal&gt;
                          &lt;/goals&gt;
                      &lt;/execution&gt;
                  &lt;/executions&gt;
              &lt;/plugin&gt;
          &lt;/plugins&gt;
      &lt;/build&gt;
  
      &lt;profiles&gt;
          &lt;profile&gt;
              &lt;id&gt;debug&lt;/id&gt;
              &lt;properties&gt;
                  &lt;build.debug&gt;true&lt;/build.debug&gt;
              &lt;/properties&gt;
          &lt;/profile&gt;
      &lt;/profiles&gt;
  
      &lt;distributionManagement&gt;
          &lt;snapshotRepository&gt;
              &lt;id&gt;snapshot&lt;/id&gt;
              &lt;name&gt;XXXXX&lt;/name&gt;
              &lt;url&gt;XXXXXX&lt;/url&gt;
          &lt;/snapshotRepository&gt;
          &lt;repository&gt;
              &lt;id&gt;release&lt;/id&gt;
              &lt;name&gt;XXXXXX&lt;/name&gt;
              &lt;url&gt;XXXXXX&lt;/url&gt;
          &lt;/repository&gt;
      &lt;/distributionManagement&gt;
  
      &lt;pluginRepositories&gt;
          &lt;pluginRepository&gt;
              &lt;id&gt;flex-mojos-plugin-repository&lt;/id&gt;
              &lt;url&gt;https://repository.sonatype.org/content/groups/flexgroup/&lt;/url&gt;
              &lt;releases&gt;
                  &lt;enabled&gt;true&lt;/enabled&gt;
                  &lt;updatePolicy&gt;always&lt;/updatePolicy&gt;
              &lt;/releases&gt;
              &lt;snapshots&gt;
                  &lt;enabled&gt;true&lt;/enabled&gt;
                  &lt;updatePolicy&gt;always&lt;/updatePolicy&gt;
              &lt;/snapshots&gt;
          &lt;/pluginRepository&gt;
          &lt;pluginRepository&gt;
              &lt;id&gt;XXXXX&lt;/id&gt;
              &lt;url&gt;XXXXXXX&lt;/url&gt;
              &lt;releases&gt;
                  &lt;enabled&gt;true&lt;/enabled&gt;
                  &lt;updatePolicy&gt;always&lt;/updatePolicy&gt;
              &lt;/releases&gt;
              &lt;snapshots&gt;
                  &lt;enabled&gt;true&lt;/enabled&gt;
                  &lt;updatePolicy&gt;always&lt;/updatePolicy&gt;
              &lt;/snapshots&gt;
          &lt;/pluginRepository&gt;
          &lt;pluginRepository&gt;
              &lt;id&gt;flexpmd.opensource.adobe&lt;/id&gt;
              &lt;releases&gt;
                  &lt;enabled&gt;true&lt;/enabled&gt;
              &lt;/releases&gt;
              &lt;snapshots&gt;
                  &lt;enabled&gt;false&lt;/enabled&gt;
              &lt;/snapshots&gt;
              &lt;name&gt;FlexPMD repository on opensource.adobe.com&lt;/name&gt;
              &lt;url&gt;http://opensource.adobe.com/svn/opensource/flexpmd/maven-repository/release/&lt;/url&gt;
          &lt;/pluginRepository&gt;
      &lt;/pluginRepositories&gt;
  
      &lt;repositories&gt;
          &lt;repository&gt;
              &lt;id&gt;XXXXX&lt;/id&gt;
              &lt;url&gt;XXXXXX&lt;/url&gt;
              &lt;releases&gt;
                  &lt;enabled&gt;true&lt;/enabled&gt;
                  &lt;updatePolicy&gt;always&lt;/updatePolicy&gt;
              &lt;/releases&gt;
              &lt;snapshots&gt;
                  &lt;enabled&gt;true&lt;/enabled&gt;
                  &lt;updatePolicy&gt;always&lt;/updatePolicy&gt;
              &lt;/snapshots&gt;
          &lt;/repository&gt;
          &lt;repository&gt;
              &lt;id&gt;flex-mojos-plugin-repository&lt;/id&gt;
              &lt;url&gt;https://repository.sonatype.org/content/groups/flexgroup/&lt;/url&gt;
              &lt;releases&gt;
                  &lt;enabled&gt;true&lt;/enabled&gt;
                  &lt;updatePolicy&gt;always&lt;/updatePolicy&gt;
              &lt;/releases&gt;
              &lt;snapshots&gt;
                  &lt;enabled&gt;true&lt;/enabled&gt;
                  &lt;updatePolicy&gt;always&lt;/updatePolicy&gt;
              &lt;/snapshots&gt;
          &lt;/repository&gt;
      &lt;/repositories&gt;
  &lt;/project&gt;
  </code></pre>