No idea if this is right, but does that mean you need a

try{}
catch();

in there?

Paul.

Paolo Missier wrote:
> I have the following beanshell script:
>
>   <script>import info.ipaw.pc3.PSLoadWorkflow.*;
>
> boolean IsCSVReadyFileExistsOutput = 
> LoadAppLogic.IsCSVReadyFileExists("/Users/paolo/Documents/myGRID/OPM/PC3/SampleData/J062941");
>
> if (IsCSVReadyFileExistsOutput) fileExists = "true";
> else fileExists = "false";
> </script>
>
> where LoadAppLogic.IsCSVReadyFileExists is a static method.
>
> This executes correctly from a snapshot workbench when I deposit the 
> external jar file info.ipaw.pc3.PSLoadWorkflow.jar into the lib/ 
> directory relative to the workbench app root.
>
> I then execute the same workflow from eclipse using a Junit test called 
> ProvenanceCaptureTest. I have tried:
>
> - adding the jar file to a newly created lib/ directory and then adding 
> the jar to the project java build path
> - adding the jar file to a newly created lib/ directory and then adding 
> the jar to the classpath in the run configuration for ProvenanceCaptureTest
>
> in all cases I get the following exception:
>
> <error message="Uncaught exception while invoking 
> net.sf.taverna.t2.activities.beanshell.beanshellactiv...@5f1c5e" 
> type="INVOCATION"><cause>java.lang.ClassLoader.defineClass1(Native Method)
> java.lang.ClassLoader.defineClass(ClassLoader.java:675)
> java.security.SecureClassLoader.defineClass(SecureClassLoader.java:124)
> java.net.URLClassLoader.defineClass(URLClassLoader.java:260)
> java.net.URLClassLoader.access$100(URLClassLoader.java:56)
> java.net.URLClassLoader$1.run(URLClassLoader.java:195)
> java.security.AccessController.doPrivileged(Native Method)
> java.net.URLClassLoader.findClass(URLClassLoader.java:188)
> java.lang.ClassLoader.loadClass(ClassLoader.java:316)
> sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:280)
> java.lang.ClassLoader.loadClass(ClassLoader.java:251)
> java.lang.ClassLoader.loadClassInternal(ClassLoader.java:374)
> java.lang.Class.forName0(Native Method)
> java.lang.Class.forName(Class.java:242)
> bsh.classpath.ClassManagerImpl.classForName(Unknown Source)
> bsh.NameSpace.classForName(Unknown Source)
> bsh.NameSpace.getImportedClassImpl(Unknown Source)
> bsh.NameSpace.getClassImpl(Unknown Source)
> bsh.NameSpace.getClass(Unknown Source)
> bsh.Name.consumeNextObjectField(Unknown Source)
> bsh.Name.toObject(Unknown Source)
> bsh.Name.toObject(Unknown Source)
> bsh.Name.invokeMethod(Unknown Source)
> bsh.BSHMethodInvocation.eval(Unknown Source)
> bsh.BSHPrimaryExpression.eval(Unknown Source)
> bsh.BSHPrimaryExpression.eval(Unknown Source)
> bsh.Interpreter.eval(Unknown Source)
> bsh.Interpreter.eval(Unknown Source)
> bsh.Interpreter.eval(Unknown Source)
> net.sf.taverna.t2.activities.beanshell.BeanshellActivity$1.run(BeanshellActivity.java:153)
> java.lang.Thread.run(Thread.java:613)
> </cause></error>
>
>
> -Paolo
>
> ------------------------------------------------------------------------------
> _______________________________________________
> taverna-hackers mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/taverna-hackers
> Developers Guide: http://www.mygrid.org.uk/usermanual1.7/dev_guide.html
> FAQ: http://www.mygrid.org.uk/wiki/Mygrid/TavernaFaq
>   


------------------------------------------------------------------------------
_______________________________________________
taverna-hackers mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/taverna-hackers
Developers Guide: http://www.mygrid.org.uk/usermanual1.7/dev_guide.html
FAQ: http://www.mygrid.org.uk/wiki/Mygrid/TavernaFaq

Reply via email to