Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Failed to execute goal org.codehaus.mojo:exec-maven-plugin:1.2.1: #30

Open
AbhiMangal opened this issue Oct 18, 2015 · 14 comments
Open

Comments

@AbhiMangal
Copy link

Sir i want to use word2vec in my project . i add it in my project , but shows this error .

Failed to execute goal org.codehaus.mojo:exec-maven-plugin:1.2.1:exec (default-cli) on project medallia-word2vec: Command execution failed. Process exited with an error: 1 (Exit value: 1) -> [Help 1]

To see the full stack trace of the errors, re-run Maven with the -e switch.
Re-run Maven using the -X switch to enable full debug logging.

i am using Netbeans 8.1 with maven . please tell me how can i remove it and use it. please guide me
how can i use it . Thanks

@guerda
Copy link
Contributor

guerda commented Oct 18, 2015

Hi AbhiMangal!

This looks like a configuration error, but without the full log file, we cannot see, what's wrong on your side. "Command execution failed" is not very specific.
Could you please paste the full log file here? Especially the part above this error message should be useful to help you.

@AbhiMangal
Copy link
Author

cd C:\Users\Abhilasha\Documents\NetBeansProjects\Word2VecJava-master; "JAVA_HOME=C:\Program Files\Java\jdk1.8.0" cmd /c """C:\Program Files\NetBeans 8.0.1\java\maven\bin\mvn.bat" -Dexec.args="-classpath %classpath com.medallia.word2vec.Word2VecExamples" -Dexec.executable="C:\Program Files\Java\jdk1.8.0\bin\java.exe" -Dmaven.ext.class.path="C:\Program Files\NetBeans 8.0.1\java\maven-nblib\netbeans-eventspy.jar" -Dfile.encoding=UTF-8 org.codehaus.mojo:exec-maven-plugin:1.2.1:exec""
Running NetBeans Compile On Save execution. Phase execution is skipped and output directories of dependency projects (with Compile on Save turned on) will be used instead of their jar artifacts.
Scanning for projects...


Building medallia-word2vec 0.10.2

--- exec-maven-plugin:1.2.1:exec (default-cli) @ medallia-word2vec ---
Acquire vocab is 0.00% complete
Filter sort vocab is 0.00% complete
Create huffman encoding is 0.00% complete
Create huffman encoding is 50.00% complete
Train neural network is 0.00% complete
SLF4J: Failed to load class "org.slf4j.impl.StaticLoggerBinder".
SLF4J: See http://www.slf4j.org/codes.html#StaticLoggerBinder for further details.
Exception in thread "main" java.lang.NoClassDefFoundError: org/slf4j/impl/StaticLoggerBinder
at org.slf4j.LoggerFactory.getSingleton(LoggerFactory.java:223)
at org.slf4j.LoggerFactory.bind(LoggerFactory.java:120)
at org.slf4j.LoggerFactory.performInitialization(LoggerFactory.java:111)
at org.slf4j.LoggerFactory.getILoggerFactory(LoggerFactory.java:269)
at org.slf4j.LoggerFactory.getLogger(LoggerFactory.java:242)
at org.apache.thrift.transport.TIOStreamTransport.(TIOStreamTransport.java:38)
at org.apache.thrift.TSerializer.(TSerializer.java:45)
at com.medallia.word2vec.util.ThriftUtils.serializeJson(ThriftUtils.java:16)
at com.medallia.word2vec.Word2VecExamples.demoWord(Word2VecExamples.java:73)
at com.medallia.word2vec.Word2VecExamples.main(Word2VecExamples.java:36)
Caused by: java.lang.ClassNotFoundException: org.slf4j.impl.StaticLoggerBinder
at java.net.URLClassLoader$1.run(URLClassLoader.java:372)
at java.net.URLClassLoader$1.run(URLClassLoader.java:361)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:360)
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)

... 10 more

BUILD FAILURE

Total time: 6.209s
Finished at: Tue Oct 27 19:50:26 IST 2015

Final Memory: 5M/124M

Failed to execute goal org.codehaus.mojo:exec-maven-plugin:1.2.1:exec (default-cli) on project medallia-word2vec: Command execution failed. Process exited with an error: 1 (Exit value: 1) -> [Help 1]

To see the full stack trace of the errors, re-run Maven with the -e switch.
Re-run Maven using the -X switch to enable full debug logging.

For more information about the errors and possible solutions, please read the following articles:
[Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoExecutionException

sir please see it once again

@guerda
Copy link
Contributor

guerda commented Oct 27, 2015

The exception shows that you are missing the class org/slf4j/impl/StaticLoggerBinder. Have you included a SLF4J Implementation (log4j, logback or something similar)?
If no, please include one of them.
For example, you could use logback:

<dependency>
  <groupId>ch.qos.logback</groupId>
  <artifactId>logback-classic</artifactId>
  <version>1.1.2</version>
</dependency>
<dependency>
  <groupId>org.slf4j</groupId>
  <artifactId>log4j-over-slf4j</artifactId>
  <version>1.7.12</version>
</dependency>

Then you can configure logback as usual: http://logback.qos.ch/manual/configuration.html

@AbhiMangal
Copy link
Author

alredy add this file sir ..

@guerda
Copy link
Contributor

guerda commented Oct 28, 2015

Have you added the dependencies mentioned above? Have you created a logback.xml?

@AbhiMangal
Copy link
Author

Yes sir , Now its running , But which word is not containing in data set then give the error just like 👍
d C:\Users\Abhilasha\Documents\NetBeansProjects\Word2VecJava-master; "JAVA_HOME=C:\Program Files\Java\jdk1.8.0" cmd /c """C:\Program Files\NetBeans 8.0.1\java\maven\bin\mvn.bat" -Dexec.args="-classpath %classpath com.medallia.word2vec.Word2VecExamples" -Dexec.executable="C:\Program Files\Java\jdk1.8.0\bin\java.exe" -Dexec.classpathScope=runtime -Dmaven.ext.class.path="C:\Program Files\NetBeans 8.0.1\java\maven-nblib\netbeans-eventspy.jar" -Dfile.encoding=UTF-8 org.codehaus.mojo:exec-maven-plugin:1.2.1:exec""
Running NetBeans Compile On Save execution. Phase execution is skipped and output directories of dependency projects (with Compile on Save turned on) will be used instead of their jar artifacts.
Scanning for projects...


Building medallia-word2vec 0.10.2

--- exec-maven-plugin:1.2.1:exec (default-cli) @ medallia-word2vec ---
Acquire vocab is 0.00% complete
Filter sort vocab is 0.00% complete
Create huffman encoding is 0.00% complete
Create huffman encoding is 50.00% complete
Train neural network is 0.00% complete
Enter word or sentence (EXIT to break): instrument
Exception in thread "main" com.medallia.word2vec.Searcher$UnknownWordException: Unknown search word 'instrument'
at com.medallia.word2vec.SearcherImpl.getVector(SearcherImpl.java:78)
at com.medallia.word2vec.SearcherImpl.getMatches(SearcherImpl.java:35)
at com.medallia.word2vec.Word2VecExamples.interact(Word2VecExamples.java:137)
at com.medallia.word2vec.Word2VecExamples.demoWord(Word2VecExamples.java:82)

at com.medallia.word2vec.Word2VecExamples.main(Word2VecExamples.java:36)

BUILD FAILURE

Total time: 15.533s
Finished at: Wed Oct 28 23:16:15 IST 2015

Final Memory: 6M/127M

Failed to execute goal org.codehaus.mojo:exec-maven-plugin:1.2.1:exec (default-cli) on project medallia-word2vec: Command execution failed. Process exited with an error: 1 (Exit value: 1) -> [Help 1]

To see the full stack trace of the errors, re-run Maven with the -e switch.
Re-run Maven using the -X switch to enable full debug logging.

For more information about the errors and possible solutions, please read the following articles:
[Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoExecutionException

@AbhiMangal
Copy link
Author

May i run this project without maven??

@AbhiMangal
Copy link
Author

Thanks for ur response.

@guerda
Copy link
Contributor

guerda commented Oct 29, 2015

You can run Word2VecJava without Maven. You have to include all dependencies in the classpath and then you can run them.

@AbhiMangal
Copy link
Author

Yes sir , Now its running , But which word is not containing in data set then give the error just like 👍
d C:\Users\Abhilasha\Documents\NetBeansProjects\Word2VecJava-master; "JAVA_HOME=C:\Program Files\Java\jdk1.8.0" cmd /c """C:\Program Files\NetBeans 8.0.1\java\maven\bin\mvn.bat" -Dexec.args="-classpath %classpath com.medallia.word2vec.Word2VecExamples" -Dexec.executable="C:\Program Files\Java\jdk1.8.0\bin\java.exe" -Dexec.classpathScope=runtime -Dmaven.ext.class.path="C:\Program Files\NetBeans 8.0.1\java\maven-nblib\netbeans-eventspy.jar" -Dfile.encoding=UTF-8 org.codehaus.mojo:exec-maven-plugin:1.2.1:exec""
Running NetBeans Compile On Save execution. Phase execution is skipped and output directories of dependency projects (with Compile on Save turned on) will be used instead of their jar artifacts.
Scanning for projects...

Building medallia-word2vec 0.10.2

--- exec-maven-plugin:1.2.1:exec (default-cli) @ medallia-word2vec ---
Acquire vocab is 0.00% complete
Filter sort vocab is 0.00% complete
Create huffman encoding is 0.00% complete
Create huffman encoding is 50.00% complete
Train neural network is 0.00% complete
Enter word or sentence (EXIT to break): instrument
Exception in thread "main" com.medallia.word2vec.Searcher$UnknownWordException: Unknown search word 'instrument'
at com.medallia.word2vec.SearcherImpl.getVector(SearcherImpl.java:78)
at com.medallia.word2vec.SearcherImpl.getMatches(SearcherImpl.java:35)
at com.medallia.word2vec.Word2VecExamples.interact(Word2VecExamples.java:137)
at com.medallia.word2vec.Word2VecExamples.demoWord(Word2VecExamples.java:82)

at com.medallia.word2vec.Word2VecExamples.main(Word2VecExamples.java:36)

BUILD FAILURE

Total time: 15.533s
Finished at: Wed Oct 28 23:16:15 IST 2015

Final Memory: 6M/127M

Failed to execute goal org.codehaus.mojo:exec-maven-plugin:1.2.1:exec (default-cli) on project medallia-word2vec: Command execution failed. Process exited with an error: 1 (Exit value: 1) -> [Help 1]

To see the full stack trace of the errors, re-run Maven with the -e switch.
Re-run Maven using the -X switch to enable full debug logging.

For more information about the errors and possible solutions, please read the following articles:
[Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoExecutionException

@guerda
Copy link
Contributor

guerda commented Oct 30, 2015

Yes, this is correct and expected behavior. Please use com.medallia.word2vec.Searcher.contains(String) to check if a word is in the trained vocabulary before accessing it via getMatches() otherwise it will throw an Exception (as seen in the log)

@bismaya123
Copy link

bismaya123 commented Feb 8, 2018

Hi, Can anyone help me to understand what is the reason for failure. Below are the stacktrace error details.
com.trgr.filetransformerwkhtml.exception.WkHtmlException: WkHtmlToPdfException: ExecuteException occured while executing a WKHtmltoPdf command:
at com.trgr.filetransformerwkhtml.wkpdf.WkHtmlToPdfConverter.convertHTMLtoPDFWindows(WkHtmlToPdfConverter.java:239)
at com.trgr.filetransformerwkhtml.wkpdf.WkHtmlToPdfConverter.convertWKHtmlToPdf(WkHtmlToPdfConverter.java:109)
at com.trgr.filetransformerwkhtml.transform.ListenerServiceImpl.processJob(ListenerServiceImpl.java:318)
at com.trgr.filetransformerwkhtml.jms.JobMessageListener.onMessage(JobMessageListener.java:121)
at org.springframework.jms.listener.AbstractMessageListenerContainer.doInvokeListener(AbstractMessageListenerContainer.java:746)
at org.springframework.jms.listener.AbstractMessageListenerContainer.invokeListener(AbstractMessageListenerContainer.java:684)
at org.springframework.jms.listener.AbstractMessageListenerContainer.doExecuteListener(AbstractMessageListenerContainer.java:651)
at org.springframework.jms.listener.AbstractPollingMessageListenerContainer.doReceiveAndExecute(AbstractPollingMessageListenerContainer.java:317)
at org.springframework.jms.listener.AbstractPollingMessageListenerContainer.receiveAndExecute(AbstractPollingMessageListenerContainer.java:255)
at org.springframework.jms.listener.DefaultMessageListenerContainer$AsyncMessageListenerInvoker.invokeListener(DefaultMessageListenerContainer.java:1166)
at org.springframework.jms.listener.DefaultMessageListenerContainer$AsyncMessageListenerInvoker.executeOngoingLoop(DefaultMessageListenerContainer.java:1158)
at org.springframework.jms.listener.DefaultMessageListenerContainer$AsyncMessageListenerInvoker.run(DefaultMessageListenerContainer.java:1055)
at java.lang.Thread.run(Thread.java:745)
Caused by: org.apache.commons.exec.ExecuteException: Process exited with an error: 1 (Exit value: 1)
at org.apache.commons.exec.DefaultExecutor.executeInternal(DefaultExecutor.java:404)
at org.apache.commons.exec.DefaultExecutor.execute(DefaultExecutor.java:166)
at org.apache.commons.exec.DefaultExecutor.execute(DefaultExecutor.java:153)
at com.trgr.filetransformerwkhtml.wkpdf.WkHtmlToPdfConverter.convertHTMLtoPDFWindows(WkHtmlToPdfConverter.java:211)
... 12 more

@TabrizGuliyev
Copy link

I also have this problem:

Failed to execute goal org.codehaus.mojo:exec-maven-plugin:1.2.1:exec (default-cli) on project demo: Command execution failed. Process exited with an error: 1 (Exit value: 1) -> [Help 1]

To see the full stack trace of the errors, re-run Maven with the -e switch.
Re-run Maven using the -X switch to enable full debug logging.

For more information about the errors and possible solutions, please read the following articles:
[Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoExecutionException

@ElonLotfi
Copy link

same problem , any Solution ?

[INFO] Building stoneage 1.0-SNAPSHOT
[INFO] ------------------------------------------------------------------------
[INFO]
[INFO] --- exec-maven-plugin:1.6.0:exec (default-cli) @ stoneage ---
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 0.630 s
[INFO] Finished at: 2019-11-03T21:57:47+01:00
[INFO] Final Memory: 7M/155M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.codehaus.mojo:exec-maven-plugin:1.6.0:exec (default-cli) on project stoneage: The parameter 'executable' is missing or invalid -> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoExecutionException

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

No branches or pull requests

5 participants