18 January 2026:
Sahi Pro is an enterprise grade test automation platform which can automate web, mobile, API, windows and java based applications and SAP.
This forum is now archived and is in read-only mode. Please continue discussions on our improved new Sahi Pro Community forum.
Sahi Pro is an enterprise grade test automation platform which can automate web, mobile, API, windows and java based applications and SAP.
Install issue: Could not find the main class: net.sf.sahi.Proxy.
Hi
I have the latest sahi revision 20090521
and the latest java revsion (Java 6) oka Java 1.6.0_15
However when I run the bat file I get the following output
C:\>sahi\bin\sahi.bat
C:\>SET PATH="C:\Program Files\Java\jre6\bin";C:\Program Files\Windows Resource
Kits\Tools\;C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\System32\Wbem;C:\Program F
iles\Subversion\bin;C:\Program Files\TortoiseSVN\bin;C:\Program Files\Java
C:\>SET EXT_CLASS_PATH=;
C:\>REM eg. SET EXT_CLASS_PATH=;;..\extlib\db\mysql-connector-java-5.0.4-bin.jar
C:\>SET SAHI_CLASS_PATH=..\lib\sahi.jar;..\extlib\rhino\js.jar;..\extlib\apc\com
mons-codec-1.3.jar
C:\>REM SET MOZ_NO_REMOTE=1
C:\>java -classpath ;;..\lib\sahi.jar;..\extlib\rhino\js.jar;..\extlib\apc\commo
ns-codec-1.3.jar net.sf.sahi.Proxy
Exception in thread "main" java.lang.NoClassDefFoundError: net/sf/sahi/Proxy
Caused by: java.lang.ClassNotFoundException: net.sf.sahi.Proxy
at java.net.URLClassLoader$1.run(Unknown Source)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(Unknown Source)
at java.lang.ClassLoader.loadClass(Unknown Source)
at sun.misc.Launcher$AppClassLoader.loadClass(Unknown Source)
at java.lang.ClassLoader.loadClass(Unknown Source)
at java.lang.ClassLoader.loadClassInternal(Unknown Source)
Could not find the main class: net.sf.sahi.Proxy. Program will exit.
As can be seen from the output above I have already added Java to the classPath.
Can anyhow help me get Sahi up and running again please.
Thanks
Tom
I have the latest sahi revision 20090521
and the latest java revsion (Java 6) oka Java 1.6.0_15
However when I run the bat file I get the following output
C:\>sahi\bin\sahi.bat
C:\>SET PATH="C:\Program Files\Java\jre6\bin";C:\Program Files\Windows Resource
Kits\Tools\;C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\System32\Wbem;C:\Program F
iles\Subversion\bin;C:\Program Files\TortoiseSVN\bin;C:\Program Files\Java
C:\>SET EXT_CLASS_PATH=;
C:\>REM eg. SET EXT_CLASS_PATH=;;..\extlib\db\mysql-connector-java-5.0.4-bin.jar
C:\>SET SAHI_CLASS_PATH=..\lib\sahi.jar;..\extlib\rhino\js.jar;..\extlib\apc\com
mons-codec-1.3.jar
C:\>REM SET MOZ_NO_REMOTE=1
C:\>java -classpath ;;..\lib\sahi.jar;..\extlib\rhino\js.jar;..\extlib\apc\commo
ns-codec-1.3.jar net.sf.sahi.Proxy
Exception in thread "main" java.lang.NoClassDefFoundError: net/sf/sahi/Proxy
Caused by: java.lang.ClassNotFoundException: net.sf.sahi.Proxy
at java.net.URLClassLoader$1.run(Unknown Source)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(Unknown Source)
at java.lang.ClassLoader.loadClass(Unknown Source)
at sun.misc.Launcher$AppClassLoader.loadClass(Unknown Source)
at java.lang.ClassLoader.loadClass(Unknown Source)
at java.lang.ClassLoader.loadClassInternal(Unknown Source)
Could not find the main class: net.sf.sahi.Proxy. Program will exit.
As can be seen from the output above I have already added Java to the classPath.
Can anyhow help me get Sahi up and running again please.
Thanks
Tom
This discussion has been closed.
Comments
You will need to cd to sahi/bin and then run sahi.bat.
If you want to run from anywhere, add
cd /d %~dp0
at the start of sahi.bat
Regards,
Narayan
Yeap that did it nicely.
I guess SAHI was not as 'idiot-proof' as you thought
Cheers for getting me back up and running again. Looking forward to see what new features there are in the latest version.
Cheers
Tom
When I run the bat file I getting following output
c:\sahi\bin\sahi.bat
Exception in thread "main" java.lang.NoClassDefFoundError: net/sf/sahi/Proxy
Caused by: java.lang.ClassNotFoundException: net.sf.sahi.Proxy
at java.net.URLClassLoader$1.run(Unknown Source)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(Unknown Source)
at java.lang.ClassLoader.loadClass(Unknown Source)
at sun.misc.Launcher$AppClassLoader.loadClass(Unknown Source)
at java.lang.ClassLoader.loadClass(Unknown Source)
at java.lang.ClassLoader.loadClassInternal(Unknown Source)
Could not find the main class: net.sf.sahi.Proxy. Program will exit.
Please help me in resolving it.
Thanks!
Sangameshwar B