18 January 2026:


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.

Sahi controller doesn't appears (IE6 or Firefox)

gpiogpio Members
edited August 2009 in Sahi - Open Source
Hi all,
I am new in Sahi and I will need your help on this.

1) fire the sahi.bat
2)setup the IE using the localhost sahi proxy
3) visit the google.com and press CTL+ALT + double click but the controller didn't appeared.

I tried also -> http://sahi.co.in/w/help-the-sahi-controller-does-not-come-up
but still didn't worked.
Also in the console nothing appeared.

Any ideas about what is happening ?

Comments

  • dpdp Members
    instead of "localhost" try using the ip address or machine name
  • gpiogpio Members
    i tryied but it didn't make any difference
  • gpiogpio Members
    I finally did it.

    instead of localhost I used my local IP and I configured also our external proxy in sahi.
    Now I can access Google etc,
    but when i tried in our target web application i get an error:

    java.io.IOException: Stream closed
    at java.io.BufferedInputStream.getInIfOpen(Unknown Source)
    at java.io.BufferedInputStream.fill(Unknown Source)
    at java.io.BufferedInputStream.read1(Unknown Source)
    at java.io.BufferedInputStream.read(Unknown Source)
    at java.io.BufferedInputStream.fill(Unknown Source)
    at java.io.BufferedInputStream.read1(Unknown Source)
    at java.io.BufferedInputStream.read(Unknown Source)
    at net.sf.sahi.util.Utils.getBytes(Utils.java:66)
    at net.sf.sahi.response.HttpModifiedResponse.sampleBytes(HttpModifiedRes
    ponse.java:129)
    at net.sf.sahi.response.HttpModifiedResponse.getSampleContent(HttpModifi
    edResponse.java:141)
    at net.sf.sahi.response.HttpModifiedResponse.getSampleContent(HttpModifi
    edResponse.java:120)
    at net.sf.sahi.response.HttpModifiedResponse.isXHTML(HttpModifiedRespons
    e.java:72)
    at net.sf.sahi.response.HttpModifiedResponse.<init>(HttpModifiedResponse
    .java:51)
    at net.sf.sahi.RemoteRequestProcessor.processHttp(RemoteRequestProcessor
    .java:107)
    at net.sf.sahi.RemoteRequestProcessor.processHttp(RemoteRequestProcessor
    .java:70)
    at net.sf.sahi.ProxyProcessor.processAsProxy(ProxyProcessor.java:129)
    at net.sf.sahi.ProxyProcessor.run(ProxyProcessor.java:86)
    at net.sf.sahi.ProxyProcessor.processConnect(ProxyProcessor.java:219)
    at net.sf.sahi.ProxyProcessor.processAsProxy(ProxyProcessor.java:121)
    at net.sf.sahi.ProxyProcessor.run(ProxyProcessor.java:86)
    at java.lang.Thread.run(Unknown Source)
    java.lang.NullPointerException
    at java.lang.String.<init>(Unknown Source)
    at net.sf.sahi.response.HttpModifiedResponse.getSampleContent(HttpModifi
    edResponse.java:141)
    at net.sf.sahi.response.HttpModifiedResponse.getSampleContent(HttpModifi
    edResponse.java:120)
    at net.sf.sahi.response.HttpModifiedResponse.isXHTML(HttpModifiedRespons
    e.java:72)
    at net.sf.sahi.response.HttpModifiedResponse.<init>(HttpModifiedResponse
    .java:51)
    at net.sf.sahi.RemoteRequestProcessor.processHttp(RemoteRequestProcessor
    .java:107)
    at net.sf.sahi.RemoteRequestProcessor.processHttp(RemoteRequestProcessor
    .java:70)
    at net.sf.sahi.ProxyProcessor.processAsProxy(ProxyProcessor.java:129)
    at net.sf.sahi.ProxyProcessor.run(ProxyProcessor.java:86)
    at net.sf.sahi.ProxyProcessor.processConnect(ProxyProcessor.java:219)
    at net.sf.sahi.ProxyProcessor.processAsProxy(ProxyProcessor.java:121)
    at net.sf.sahi.ProxyProcessor.run(ProxyProcessor.java:86)
    at java.lang.Thread.run(Unknown Source)
    java.lang.NullPointerException
    at net.sf.sahi.ProxyProcessor.processAsProxy(ProxyProcessor.java:130)
    at net.sf.sahi.ProxyProcessor.run(ProxyProcessor.java:86)
    at net.sf.sahi.ProxyProcessor.processConnect(ProxyProcessor.java:219)
    at net.sf.sahi.ProxyProcessor.processAsProxy(ProxyProcessor.java:121)
    at net.sf.sahi.ProxyProcessor.run(ProxyProcessor.java:86)
    at java.lang.Thread.run(Unknown Source)
    java.io.IOException: Stream closed
    at java.io.BufferedInputStream.getInIfOpen(Unknown Source)
    at java.io.BufferedInputStream.fill(Unknown Source)
    at java.io.BufferedInputStream.read1(Unknown Source)
    at java.io.BufferedInputStream.read(Unknown Source)
    at java.io.BufferedInputStream.fill(Unknown Source)
    at java.io.BufferedInputStream.read1(Unknown Source)
    at java.io.BufferedInputStream.read(Unknown Source)
    at net.sf.sahi.util.Utils.getBytes(Utils.java:66)
    at net.sf.sahi.response.HttpModifiedResponse.sampleBytes(HttpModifiedRes
    ponse.java:129)
    at net.sf.sahi.response.HttpModifiedResponse.getSampleContent(HttpModifi
    edResponse.java:141)
    at net.sf.sahi.response.HttpModifiedResponse.getSampleContent(HttpModifi
    edResponse.java:120)
    at net.sf.sahi.response.HttpModifiedResponse.isXHTML(HttpModifiedRespons
    e.java:72)
    at net.sf.sahi.response.HttpModifiedResponse.<init>(HttpModifiedResponse
    .java:51)
    at net.sf.sahi.RemoteRequestProcessor.processHttp(RemoteRequestProcessor
    .java:107)
    at net.sf.sahi.RemoteRequestProcessor.processHttp(RemoteRequestProcessor
    .java:70)
    at net.sf.sahi.ProxyProcessor.processAsProxy(ProxyProcessor.java:129)
    at net.sf.sahi.ProxyProcessor.run(ProxyProcessor.java:86)
    at net.sf.sahi.ProxyProcessor.processConnect(ProxyProcessor.java:219)
    at net.sf.sahi.ProxyProcessor.processAsProxy(ProxyProcessor.java:121)
    at net.sf.sahi.ProxyProcessor.run(ProxyProcessor.java:86)
    at java.lang.Thread.run(Unknown Source)
    java.lang.NullPointerException
    at java.lang.String.<init>(Unknown Source)
    at net.sf.sahi.response.HttpModifiedResponse.getSampleContent(HttpModifi
    edResponse.java:141)
    at net.sf.sahi.response.HttpModifiedResponse.getSampleContent(HttpModifi
    edResponse.java:120)
    at net.sf.sahi.response.HttpModifiedResponse.isXHTML(HttpModifiedRespons
    e.java:72)
    at net.sf.sahi.response.HttpModifiedResponse.<init>(HttpModifiedResponse
    .java:51)
    at net.sf.sahi.RemoteRequestProcessor.processHttp(RemoteRequestProcessor
    .java:107)
    at net.sf.sahi.RemoteRequestProcessor.processHttp(RemoteRequestProcessor
    .java:70)
    at net.sf.sahi.ProxyProcessor.processAsProxy(ProxyProcessor.java:129)
    at net.sf.sahi.ProxyProcessor.run(ProxyProcessor.java:86)
    at net.sf.sahi.ProxyProcessor.processConnect(ProxyProcessor.java:219)
    at net.sf.sahi.ProxyProcessor.processAsProxy(ProxyProcessor.java:121)
    at net.sf.sahi.ProxyProcessor.run(ProxyProcessor.java:86)
    at java.lang.Thread.run(Unknown Source)
    java.lang.NullPointerException
    at net.sf.sahi.ProxyProcessor.processAsProxy(ProxyProcessor.java:130)
    at net.sf.sahi.ProxyProcessor.run(ProxyProcessor.java:86)
    at net.sf.sahi.ProxyProcessor.processConnect(ProxyProcessor.java:219)
    at net.sf.sahi.ProxyProcessor.processAsProxy(ProxyProcessor.java:121)
    at net.sf.sahi.ProxyProcessor.run(ProxyProcessor.java:86)
    at java.lang.Thread.run(Unknown Source)
  • narayannarayan Administrators
    Does your site use 401 authentication?
    Does it normally show up a dialog asking for username/password, when used without Sahi?

    Additionally, do you need the external proxy to access your target website, or do you normally bypass proxy for your application?
  • gpiogpio Members
    edited August 2009
    No the application under test is in our local lan IP so there is no need for external proxy configuration.
    I did that just to play around with record play in public web sites.


    Concerning the 401 authentication I am not really sure.
    The 1rst page requests a username/passwd but not in a pop up dialog.

    By the way now without change anything I can access both public & local web applications but I lost again sahi controller!!!!!

    .....I am totally lost....
  • narayannarayan Administrators
    gpio,

    Do not set an external proxy for your local application.

    You either set
    ext.http.proxy.enable=false
    or set
    ext.http.both.proxy.bypass_hosts=*.yourdomain.com|yourip

    I would suggest, first try with ext.http.proxy.enable=false

    Basically let Sahi hit your application without an external proxy.

    Once you do this,
    1) Clear your firefox cache.
    2) Navigate to your site using firefox,
    3) Right click -> View Page Source
    4) Check if there is a line with "concat.js" in the top 5 lines.

    If yes, your proxy settings are right.
    If you do not see concat.js, something is wrong.

    Let me know what you see till this point.
  • gpiogpio Members
    External proxy is disabled.

    with IE i can access my local application just fine.
    When I run sahi.bat & set the IE proxy as my IP

    I get the following error:

    >>>> Sahi started. Listening on port:9999
    >>>> Configure your browser to use this server and port as its proxy
    >>>> Browse any page and CTRL-ALT-DblClick on the page to bring up the Sahi Controller

    java.lang.StringIndexOutOfBoundsException: String index out of range: -9
    at java.lang.String.substring(Unknown Source)
    at net.sf.sahi.response.HttpResponse.status(HttpResponse.java:65)
    at net.sf.sahi.RemoteRequestProcessor.processHttp(RemoteRequestProcessor.java:105)
    at net.sf.sahi.RemoteRequestProcessor.processHttp(RemoteRequestProcessor.java:70)
    at net.sf.sahi.ProxyProcessor.processAsProxy(ProxyProcessor.java:129)
    at net.sf.sahi.ProxyProcessor.run(ProxyProcessor.java:86)
    at java.lang.Thread.run(Unknown Source)
    java.lang.NullPointerException
    at net.sf.sahi.ProxyProcessor.processAsProxy(ProxyProcessor.java:130)
    at net.sf.sahi.ProxyProcessor.run(ProxyProcessor.java:86)
    at java.lang.Thread.run(Unknown Source)
Sign In or Register to comment.