Re: JythonScriptExecutionException: No module named
Curtis Rueden <[email protected]> Thu, 2 Jul 2015 14:21:37 -0500
| Newsgroups | gmane.comp.lang.jython.user,gmane.comp.java.grinder.user |
|---|---|
| Message-ID | <CADN69ykjM6FeDv3uMrONR2V8ged9HKoKxv1WJrC8Fg3S8u6R3A@mail.gmail.com> |
Hi Hrishi, > now I am having to specify each and every jar that my JUnit test class > uses in the class path. Isn't there a simpler way that involves not > having to search and specify all required jars? https://code.google.com/p/grinder-maven-plugin/ ? But I know literally nothing about Grinder. Just a shot in the dark! Regards, Curtis On Thu, Jul 2, 2015 at 12:54 PM, Hrishikesh P <[email protected]> wrote: > Never mind, I was specifying the test-sources jar instead of the tests > jar. Once I corrected this, this error was gone. > > But, now I am having to specify each and every jar that my JUnit test > class uses in the class path. Isn't there a simpler way that involves not > having to search and specify all required jars? > > > On Thu, Jul 2, 2015 at 11:45 AM, Hrishikesh P <[email protected]> > wrote: > >> Hello, >> >> I am running into a Jython module import issue while starting the grinder >> agent. This is a JUnit test class that I'm trying to import. >> >> The command that I'm invoking is: >> >> >> java -cp >> ~/grinder-3.11/lib/grinder.jar:~/test/target/myapp-1.0.0-SNAPSHOT-test-sources.jar >> net.grinder.Grinder >> >> >> >> and this is my complete output: >> >> >> >> 2015-07-01 10:55:14,948 INFO agent: The Grinder 3.11 >> >> 2015-07-01 10:55:14,967 WARN agent: Failed to connect to 'localhost/ >> 127.0.0.1:6372', proceeding without the console; set >> grinder.useConsole=false to disable this warning. >> >> 2015-07-01 10:55:14,974 INFO agent: Worker process command line: java >> '-javaagent:/Users/user/grinder-3.11/lib/grinder-dcr-agent-3.11.jar' >> -classpath >> '/Users/user/grinder-3.11/lib/grinder.jar:/Users/user/test/target/myapp-1.0.0-SNAPSHOT-test-sources.jar' >> net.grinder.engine.process.WorkerProcessEntryPoint >> >> 2015-07-01 10:55:15,045 INFO agent: worker MAC-USER-0 started >> >> ['.', '.', '/Users/user/grinder-3.11/lib/Lib', >> '/Users/user/grinder-3.11/lib/jython-standalone-2.5.3.jar/Lib', >> '__classpath__', '__pyclasspath__/', >> '/Users/user/test/target/myapp-1.0.0-SNAPSHOT-test-sources.jar'] >> >> 2015-07-01 10:55:16,774 ERROR MAC-USER-0: aborting process - Jython >> exception, <type 'exceptions.ImportError'>: No module named mytest >> [initialising test script] >> >> net.grinder.scriptengine.jython.JythonScriptExecutionException: <type >> 'exceptions.ImportError'>: No module named mytest >> >> from mytest import BaseTest >> >> File "./grinder.py", line 9, in <module> >> >> 2015-07-01 10:55:16,787 INFO agent: finished >> >> >> >> Any pointers will be appreciated. >> >> >> I'm new to Grinder and have little to no experience with Jython (but a >> bit more experienced in Python). >> >> >> Thanks much in advance! >> > > > > ------------------------------------------------------------------------------ > Don't Limit Your Business. Reach for the Cloud. > GigeNET's Cloud Solutions provide you with the tools and support that > you need to offload your IT needs and focus on growing your business. > Configured For All Businesses. Start Your Cloud Today. > https://www.gigenetcloud.com/ > > _______________________________________________ > Jython-users mailing list > [email protected] > https://lists.sourceforge.net/lists/listinfo/jython-users > > ------------------------------------------------------------------------------ Don't Limit Your Business. Reach for the Cloud. GigeNET's Cloud Solutions provide you with the tools and support that you need to offload your IT needs and focus on growing your business. Configured For All Businesses. Start Your Cloud Today. https://www.gigenetcloud.com/ _______________________________________________ Jython-users mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/jython-users