weixin_39929683
weixin_39929683
2020-12-29 22:51

Initial build on NetBeans fails.

After downloading the latest zip file and unzip it on my PC, I opened the project using NetBeans. then I did a "Clean and Build" but after a while I got the following error message:


Executing: gradle clean build
Arguments: [-c, E:\AppData\NetBeansProjects\JavaFX\JavaFxGradlePlugin\javafx-gradle-plugin-newyear2018release\settings.gradle]

> Task :clean UP-TO-DATE
Download https://repo.maven.apache.org/maven2/com/puppycrawl/tools/checkstyle/6.19/checkstyle-6.19.pom
Download https://repo.maven.apache.org/maven2/commons-cli/commons-cli/1.3.1/commons-cli-1.3.1.pom
Download https://repo.maven.apache.org/maven2/com/google/guava/guava/19.0/guava-19.0.pom
Download https://repo.maven.apache.org/maven2/commons-beanutils/commons-beanutils/1.9.2/commons-beanutils-1.9.2.pom
Download https://repo.maven.apache.org/maven2/com/google/guava/guava-parent/19.0/guava-parent-19.0.pom
Download https://repo.maven.apache.org/maven2/org/antlr/antlr4-runtime/4.5.3/antlr4-runtime-4.5.3.pom
Download https://repo.maven.apache.org/maven2/com/puppycrawl/tools/checkstyle/6.19/checkstyle-6.19.jar
Download https://repo.maven.apache.org/maven2/commons-cli/commons-cli/1.3.1/commons-cli-1.3.1.jar
Download https://repo.maven.apache.org/maven2/commons-beanutils/commons-beanutils/1.9.2/commons-beanutils-1.9.2.jar
Download https://repo.maven.apache.org/maven2/com/google/guava/guava/19.0/guava-19.0.jar
Download https://repo.maven.apache.org/maven2/org/antlr/antlr4-runtime/4.5.3/antlr4-runtime-4.5.3.jar
> Task :checkstyle

> Task :compileJava
Note: E:\AppData\NetBeansProjects\JavaFX\JavaFxGradlePlugin\javafx-gradle-plugin-newyear2018release\src\main\java\de\dynamicfiles\projects\gradle\plugins\javafx\tasks\internal\MonkeyPatcher.java uses or overrides a deprecated API.
Note: Recompile with -Xlint:deprecation for details.

> Task :processResources
> Task :classes
> Task :jar

> Task :javadoc
java.lang.IllegalArgumentException
    at sun.net.www.ParseUtil.decode(ParseUtil.java:202)
    at sun.misc.URLClassPath$FileLoader.<init>(URLClassPath.java:1241)
    at sun.misc.URLClassPath$3.run(URLClassPath.java:560)
    at sun.misc.URLClassPath$3.run(URLClassPath.java:555)
    at java.security.AccessController.doPrivileged(Native Method)
    at sun.misc.URLClassPath.getLoader(URLClassPath.java:554)
    at sun.misc.URLClassPath.getLoader(URLClassPath.java:519)
    at sun.misc.URLClassPath.getNextLoader(URLClassPath.java:484)
    at sun.misc.URLClassPath.access$100(URLClassPath.java:65)
    at sun.misc.URLClassPath$1.next(URLClassPath.java:266)
    at sun.misc.URLClassPath$1.hasMoreElements(URLClassPath.java:277)
    at java.net.URLClassLoader$3$1.run(URLClassLoader.java:601)
    at java.net.URLClassLoader$3$1.run(URLClassLoader.java:599)
    at java.security.AccessController.doPrivileged(Native Method)
    at java.net.URLClassLoader$3.next(URLClassLoader.java:598)
    at java.net.URLClassLoader$3.hasMoreElements(URLClassLoader.java:623)
    at sun.misc.CompoundEnumeration.next(CompoundEnumeration.java:45)
    at sun.misc.CompoundEnumeration.hasMoreElements(CompoundEnumeration.java:54)
    at java.util.ServiceLoader$LazyIterator.hasNextService(ServiceLoader.java:354)
    at java.util.ServiceLoader$LazyIterator.hasNext(ServiceLoader.java:393)
    at java.util.ServiceLoader$1.hasNext(ServiceLoader.java:474)
    at javax.xml.parsers.FactoryFinder$1.run(FactoryFinder.java:293)
    at java.security.AccessController.doPrivileged(Native Method)
    at javax.xml.parsers.FactoryFinder.findServiceProvider(FactoryFinder.java:289)
    at javax.xml.parsers.FactoryFinder.find(FactoryFinder.java:267)
    at javax.xml.parsers.SAXParserFactory.newInstance(SAXParserFactory.java:127)
    at com.sun.tools.doclets.internal.toolkit.builders.LayoutParser.parseXML(LayoutParser.java:89)
    at com.sun.tools.doclets.internal.toolkit.builders.ClassBuilder.build(ClassBuilder.java:120)
    at com.sun.tools.doclets.formats.html.HtmlDoclet.generateClassFiles(HtmlDoclet.java:189)
    at com.sun.tools.doclets.internal.toolkit.AbstractDoclet.generateClassFiles(AbstractDoclet.java:207)
    at com.sun.tools.doclets.internal.toolkit.AbstractDoclet.generateClassFiles(AbstractDoclet.java:191)
    at com.sun.tools.doclets.internal.toolkit.AbstractDoclet.startGeneration(AbstractDoclet.java:139)
    at com.sun.tools.doclets.internal.toolkit.AbstractDoclet.start(AbstractDoclet.java:82)
    at com.sun.tools.doclets.formats.html.HtmlDoclet.start(HtmlDoclet.java:80)
    at com.sun.tools.doclets.standard.Standard.start(Standard.java:39)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    at java.lang.reflect.Method.invoke(Method.java:498)
    at com.sun.tools.javadoc.DocletInvoker.invoke(DocletInvoker.java:310)
    at com.sun.tools.javadoc.DocletInvoker.start(DocletInvoker.java:189)
    at com.sun.tools.javadoc.Start.parseAndExecute(Start.java:366)
    at com.sun.tools.javadoc.Start.begin(Start.java:219)
    at com.sun.tools.javadoc.Start.begin(Start.java:205)
    at com.sun.tools.javadoc.Main.execute(Main.java:64)
    at com.sun.tools.javadoc.Main.main(Main.java:54)
javadoc: error - java.lang.IllegalArgumentException
1 error

> Task :javadoc FAILED

FAILURE: Build failed with an exception.

* What went wrong:
Execution failed for task ':javadoc'.
> Javadoc generation failed. Generated Javadoc options file (useful for troubleshooting): 'E:\AppData\NetBeansProjects\JavaFX\JavaFxGradlePlugin\javafx-gradle-plugin-newyear2018release\build\tmp\javadoc\javadoc.options'

* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights.

* Get more help at https://help.gradle.org

BUILD FAILED in 10s
6 actionable tasks: 5 executed, 1 up-to-date



Build failure (see the Notifications window for stacktrace): gradle clean build
</init>

And this is the content of the generated Javadoc options file (referenced @ the end of the above message):


-classpath 'E:\\AppData\\NetBeansProjects\\JavaFX\\JavaFxGradlePlugin\\javafx-gradle-plugin-newyear2018release\\build\\classes\\java\\main;E:\\AppData\\NetBeansProjects\\JavaFX\\JavaFxGradlePlugin\\javafx-gradle-plugin-newyear2018release\\build\\resources\\main;D:\\WinApps\\Programming\\Gradle\\gradle-4.9\\caches\\4.9\\generated-gradle-jars\\gradle-api-4.9.jar;D:\\WinApps\\Programming\\Gradle\\gradle-4.9\\lib\\groovy-all-2.4.12.jar;D:\\WinApps\\Programming\\Gradle\\gradle-4.9\\lib\\gradle-installation-beacon-4.9.jar;D:\\WinApps\\Programming\\Java\\Oracle\\jdk_1.8\\lib\\ant-javafx.jar;D:\\WinApps\\Programming\\Gradle\\gradle-4.9\\caches\\modules-2\\files-2.1\\org.ow2.asm\\asm-all\\5.1\\ae8be205e00013dce1e31420aee506a0333d21ad\\asm-all-5.1.jar'
-d 'E:\\AppData\\NetBeansProjects\\JavaFX\\JavaFxGradlePlugin\\javafx-gradle-plugin-newyear2018release\\build\\docs\\javadoc'
-doctitle 'javafx-gradle-plugin 8.9.0-SNAPSHOT API'
-quiet 
-windowtitle 'javafx-gradle-plugin 8.9.0-SNAPSHOT API'
'E:\\AppData\\NetBeansProjects\\JavaFX\\JavaFxGradlePlugin\\javafx-gradle-plugin-newyear2018release\\src\\main\\java\\de\\dynamicfiles\\projects\\gradle\\plugins\\javafx\\dto\\FileAssociation.java'
'E:\\AppData\\NetBeansProjects\\JavaFX\\JavaFxGradlePlugin\\javafx-gradle-plugin-newyear2018release\\src\\main\\java\\de\\dynamicfiles\\projects\\gradle\\plugins\\javafx\\dto\\NativeLauncher.java'
'E:\\AppData\\NetBeansProjects\\JavaFX\\JavaFxGradlePlugin\\javafx-gradle-plugin-newyear2018release\\src\\main\\java\\de\\dynamicfiles\\projects\\gradle\\plugins\\javafx\\JavaFXGradlePlugin.java'
'E:\\AppData\\NetBeansProjects\\JavaFX\\JavaFxGradlePlugin\\javafx-gradle-plugin-newyear2018release\\src\\main\\java\\de\\dynamicfiles\\projects\\gradle\\plugins\\javafx\\JavaFXGradlePluginExtension.java'
'E:\\AppData\\NetBeansProjects\\JavaFX\\JavaFxGradlePlugin\\javafx-gradle-plugin-newyear2018release\\src\\main\\java\\de\\dynamicfiles\\projects\\gradle\\plugins\\javafx\\tasks\\internal\\JavaDetectionTools.java'
'E:\\AppData\\NetBeansProjects\\JavaFX\\JavaFxGradlePlugin\\javafx-gradle-plugin-newyear2018release\\src\\main\\java\\de\\dynamicfiles\\projects\\gradle\\plugins\\javafx\\tasks\\internal\\MonkeyPatcher.java'
'E:\\AppData\\NetBeansProjects\\JavaFX\\JavaFxGradlePlugin\\javafx-gradle-plugin-newyear2018release\\src\\main\\java\\de\\dynamicfiles\\projects\\gradle\\plugins\\javafx\\tasks\\internal\\ParameterMapEntries.java'
'E:\\AppData\\NetBeansProjects\\JavaFX\\JavaFxGradlePlugin\\javafx-gradle-plugin-newyear2018release\\src\\main\\java\\de\\dynamicfiles\\projects\\gradle\\plugins\\javafx\\tasks\\internal\\Workarounds.java'
'E:\\AppData\\NetBeansProjects\\JavaFX\\JavaFxGradlePlugin\\javafx-gradle-plugin-newyear2018release\\src\\main\\java\\de\\dynamicfiles\\projects\\gradle\\plugins\\javafx\\tasks\\JfxGenerateKeystoreTask.java'
'E:\\AppData\\NetBeansProjects\\JavaFX\\JavaFxGradlePlugin\\javafx-gradle-plugin-newyear2018release\\src\\main\\java\\de\\dynamicfiles\\projects\\gradle\\plugins\\javafx\\tasks\\JfxJarTask.java'
'E:\\AppData\\NetBeansProjects\\JavaFX\\JavaFxGradlePlugin\\javafx-gradle-plugin-newyear2018release\\src\\main\\java\\de\\dynamicfiles\\projects\\gradle\\plugins\\javafx\\tasks\\JfxListBundlersTask.java'
'E:\\AppData\\NetBeansProjects\\JavaFX\\JavaFxGradlePlugin\\javafx-gradle-plugin-newyear2018release\\src\\main\\java\\de\\dynamicfiles\\projects\\gradle\\plugins\\javafx\\tasks\\JfxNativeTask.java'
'E:\\AppData\\NetBeansProjects\\JavaFX\\JavaFxGradlePlugin\\javafx-gradle-plugin-newyear2018release\\src\\main\\java\\de\\dynamicfiles\\projects\\gradle\\plugins\\javafx\\tasks\\JfxRunTask.java'
'E:\\AppData\\NetBeansProjects\\JavaFX\\JavaFxGradlePlugin\\javafx-gradle-plugin-newyear2018release\\src\\main\\java\\de\\dynamicfiles\\projects\\gradle\\plugins\\javafx\\tasks\\workers\\JfxAbstractWorker.java'
'E:\\AppData\\NetBeansProjects\\JavaFX\\JavaFxGradlePlugin\\javafx-gradle-plugin-newyear2018release\\src\\main\\java\\de\\dynamicfiles\\projects\\gradle\\plugins\\javafx\\tasks\\workers\\JfxGenerateKeystoreWorker.java'
'E:\\AppData\\NetBeansProjects\\JavaFX\\JavaFxGradlePlugin\\javafx-gradle-plugin-newyear2018release\\src\\main\\java\\de\\dynamicfiles\\projects\\gradle\\plugins\\javafx\\tasks\\workers\\JfxJarWorker.java'
'E:\\AppData\\NetBeansProjects\\JavaFX\\JavaFxGradlePlugin\\javafx-gradle-plugin-newyear2018release\\src\\main\\java\\de\\dynamicfiles\\projects\\gradle\\plugins\\javafx\\tasks\\workers\\JfxListBundlersWorker.java'
'E:\\AppData\\NetBeansProjects\\JavaFX\\JavaFxGradlePlugin\\javafx-gradle-plugin-newyear2018release\\src\\main\\java\\de\\dynamicfiles\\projects\\gradle\\plugins\\javafx\\tasks\\workers\\JfxNativeWorker.java'
'E:\\AppData\\NetBeansProjects\\JavaFX\\JavaFxGradlePlugin\\javafx-gradle-plugin-newyear2018release\\src\\main\\java\\de\\dynamicfiles\\projects\\gradle\\plugins\\javafx\\tasks\\workers\\JfxRunWorker.java'

Any idea what could have caused this?

该提问来源于开源项目:FibreFoX/javafx-gradle-plugin

  • 点赞
  • 写回答
  • 关注问题
  • 收藏
  • 复制链接分享
  • 邀请回答

11条回答

  • weixin_39929683 weixin_39929683 3月前

    I'm using JDK 8 (1.8.0_181 to be exact). You're requesting to run mvn clean package but there's nowhere a pom file to be executed...

    点赞 评论 复制链接分享
  • weixin_39587029 weixin_39587029 3月前

    oh sorry, mixed up with the maven-equivalent :D sorry, but calling gradlew clean install should work normally

    点赞 评论 复制链接分享
  • weixin_39929683 weixin_39929683 3月前

    Thought so, but didn't want to be a smarty-pants. You're the intellectual owner of the plug-in, so who am I to push my thoughts on your creation... 😉 I've in the mean time run the gradlew clean install and that's successful. Does that mean we can't compile from NetBeans by default?

    点赞 评论 复制链接分享
  • weixin_39587029 weixin_39587029 3月前

    I'm responsible for the maven-plugin AND the gradle-plugin, and sometimes, especially on mondays, this can get mixed up inside my head ;) sorry for mixing this up and trying you to wave over to maven ;D but did it work?

    Kidding aside: for checking compile-problems I added TravisCI/AppVeyor to compile using multiple JDKs, which makes me wonder: https://travis-ci.org/FibreFoX/javafx-gradle-plugin/builds/331561718

    As Gradle-integration in Netbeans sometimes is flaky, I can't pinpoint what the problem is, in addition I can't reproduce the problems you have :/

    点赞 评论 复制链接分享
  • weixin_39929683 weixin_39929683 3月前

    You asked if it worked. As said, running from the command line is OK. But I'm still trying to figure out how to incorporate this in NetBeans.

    Some time back I installed a NetBeans plugin that allows you to create or open a project based on Gradle (plugin is called Gradle Support and installs also indirectly the plugin Groovy and Grails). But that's to create "normal" Java projects, not JavaFx based ones.

    So, my question: Using NetBeans, is it sufficient to create a JavaFx project not based on Gradle (since the Gradle Support plugin only creates "normal" Java applications) and then later on put your example build.gradle file in the project?

    I'm gonna at least try this but maybe you know the answer already upfront.

    点赞 评论 复制链接分享
  • weixin_39587029 weixin_39587029 3月前

    Now I'm confused, are you saying you downloaded this plugin-project to use as a JavaFX-boilerplate project?

    点赞 评论 复制链接分享
  • weixin_39929683 weixin_39929683 3月前

    To be honest, it's not really clear to me how to use your plugin into a NetBeans created JavaFX application... Would be good if you could guide me in how to do this, because otherwise I'm afraid we're talking parallel paths (which is obviously my problem since I don't really get a grip on it, not yours...).

    点赞 评论 复制链接分享
  • weixin_39587029 weixin_39587029 3月前

    Now I'm starting to understand 😄 to create a project, you should create a normal gradle-project, you can look into the examples: https://github.com/FibreFoX/javafx-gradle-plugin/tree/newyear2018release/examples Or just follow the instructions: https://github.com/FibreFoX/javafx-gradle-plugin#example-buildgradle

    Creating the project from Netbeans, you probably will end with some Ant-based project, so I personally create them "by hand".

    点赞 评论 复制链接分享
  • weixin_39929683 weixin_39929683 3月前

    Using it from NetBeans doesn't seem to go so smooth. Even the examples and the external references don't work "out of the box". Think I have to put some "by hand" work myself too...

    点赞 评论 复制链接分享
  • weixin_39587029 weixin_39587029 3月前

    I really don't get your situation. Creating a gradle project is easy done "by hand", working with that gradle-project does not differ when having JavaFX included. When using this plugin, you enhance your build-file of your gradle-project by adding this plugin to your build-classpath, and after that you call apply plugin... to activate this plugin.

    So using the examples, you need to adjust the classpath-parts (like shown in the instructions). You do not "copy" this plugin-project for this.

    点赞 评论 复制链接分享
  • weixin_39587029 weixin_39587029 3月前

    Which JDK are you using? Have you tried to call mvn clean package in some terminal?

    点赞 评论 复制链接分享