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.

Out of Memory Error .....with SAHI V 3.5

Akss004Akss004 Members
edited November -1 in Sahi - Open Source
Hi Narayan,

I am getting following Exception on SAHI command window quite often while starting execution. It comes randomly .

Here take a note that i have already extended Memory in SAHI.BAT file as suggested in some of previous post's. But i don't think it has worked here in my case.

Don't why but it did not come while i was using previous version of sahi. Its not memory leakage issue cause its coming just after clicking on play button or while using with testrunner.bat just after browser getting pop's up.



Exception in thread "Thread-864" java.lang.OutOfMemoryError: Java heap space
at org.mozilla.javascript.Decompiler.increaseSourceCapacity(Decompiler.j
ava:262)
at org.mozilla.javascript.Decompiler.appendString(Decompiler.java:231)
at org.mozilla.javascript.Decompiler.addString(Decompiler.java:160)
at org.mozilla.javascript.Parser.primaryExpr(Parser.java:2433)
at org.mozilla.javascript.Parser.memberExpr(Parser.java:1955)
at org.mozilla.javascript.Parser.unaryExpr(Parser.java:1813)
at org.mozilla.javascript.Parser.mulExpr(Parser.java:1742)
at org.mozilla.javascript.Parser.addExpr(Parser.java:1723)
at org.mozilla.javascript.Parser.shiftExpr(Parser.java:1703)
at org.mozilla.javascript.Parser.relExpr(Parser.java:1677)
at org.mozilla.javascript.Parser.eqExpr(Parser.java:1633)
at org.mozilla.javascript.Parser.bitAndExpr(Parser.java:1622)
at org.mozilla.javascript.Parser.bitXorExpr(Parser.java:1611)
at org.mozilla.javascript.Parser.bitOrExpr(Parser.java:1600)
at org.mozilla.javascript.Parser.andExpr(Parser.java:1588)
at org.mozilla.javascript.Parser.orExpr(Parser.java:1576)
at org.mozilla.javascript.Parser.condExpr(Parser.java:1559)
at org.mozilla.javascript.Parser.assignExpr(Parser.java:1544)
at org.mozilla.javascript.Parser.argumentList(Parser.java:1910)
at org.mozilla.javascript.Parser.memberExprTail(Parser.java:2050)
at org.mozilla.javascript.Parser.memberExpr(Parser.java:1958)
at org.mozilla.javascript.Parser.unaryExpr(Parser.java:1813)
at org.mozilla.javascript.Parser.mulExpr(Parser.java:1742)
at org.mozilla.javascript.Parser.addExpr(Parser.java:1723)
at org.mozilla.javascript.Parser.shiftExpr(Parser.java:1703)
at org.mozilla.javascript.Parser.relExpr(Parser.java:1677)
at org.mozilla.javascript.Parser.eqExpr(Parser.java:1633)
at org.mozilla.javascript.Parser.bitAndExpr(Parser.java:1622)
at org.mozilla.javascript.Parser.bitXorExpr(Parser.java:1611)
at org.mozilla.javascript.Parser.bitOrExpr(Parser.java:1600)
at org.mozilla.javascript.Parser.andExpr(Parser.java:1588)
at org.mozilla.javascript.Parser.orExpr(Parser.java:1576)

Comments

  • narayannarayan Administrators
    Hi Akash,

    Take a script which causes this, and delete content from it, till you can pinpoint what part of the code causes this. Culprit could be in an included file or in some external library that you use.

    Regards,
    Narayan
  • Thanx for your quick response as always narayan,

    But as i have mentioned here that its having randomize behavior i am not able to reproduce it every time and in that case trial and run method to find root cause will be time consuming.


    I am having 15 scripts included in Main Driver Script and which will execute test case function by searching it run time from those script files.

    So does this list of included files is cause of this kind of error??

    And is there any work around with these..... cause we follow agile methodology in development phase so this list of scripts going to get longer and longer. And if this error came frequently it will hurt my automation frame works performance.
  • narayannarayan Administrators
    Hi Akash,

    We run about a 1000 scripts as part of our own testing. We do not get this error. You cannot escape from narrowing down the cause this error. Unless you get the root cause, you cannot predict if more scripts will work or not.

    Regards,
    Narayan
  • Ok.

    Then I need to look after some recently added Test scripts. Thanks for your quick response this will help me in sorting out issue.
Sign In or Register to comment.