Forum Discussion

mcpm's avatar
mcpm
Occasional Contributor
2 years ago
Solved

RuntimeErrors after upgrading to 15.68.8.7

Hello,

I recently upgraded to the latest version of TestComplete, and unfortunately, I'm experiencing issues. I'm still facing a RuntimeError originating from TestComplete's native functions (I'm using it with Python scripts). The errors occur with functions like Log.Message, Log.AppendFolder, and others. However, the problem is quite random, as it's not always the same line of code that fails. As a result, I'm unable to execute any tests at the moment and will need to downgrade to the previous version.
Is anyone facing this problem as well?

  • I found a simple workaround.

    Just create an OnStartTestEvent function, hook it up to TestComplete’s OnStartTestEvent, and add this line inside:

    gc.collect()

    Don’t forget to put import gc at the top of your module.

    What this does: OnStartTestEvent is triggered right at the start of the test run, so calling gc.collect() there forces Python’s garbage collector to clean up memory before your tests begin.

     

15 Replies

  • I have the exact same issue. Testing a desktop application. Using python for scripts. Runtime error happens on TestComplete native functions.

    • mcpm's avatar
      mcpm
      Occasional Contributor

      Yes, that’s probably how it ends, but before that, I just wanted to know if anyone else has seen this as well.

  • moonlight's avatar
    moonlight
    New Contributor

    Did anyone find the workaround or solution?

    This issue is still exists in 15.74 version. 

    • mcpm's avatar
      mcpm
      Occasional Contributor

      Unfortunately, no - we're still stuck with version 15.67.

      • moonlight's avatar
        moonlight
        New Contributor

        I found a simple workaround.

        Just create an OnStartTestEvent function, hook it up to TestComplete’s OnStartTestEvent, and add this line inside:

        gc.collect()

        Don’t forget to put import gc at the top of your module.

        What this does: OnStartTestEvent is triggered right at the start of the test run, so calling gc.collect() there forces Python’s garbage collector to clean up memory before your tests begin.