Forum Discussion
I have received a patched build (Version: 15.78.93.7) from SmartBear support with the following workaround:
After discussion with the Development team, it is confirmed that this is a bug introduced in TestComplete 15.77 and the change from Python version 3.11 to 3.13.
Our development team has provided a release build that includes the Python Runtime fix for TestComplete 15.78 to resolve the import issue. The official release will be available in 15.79, which should be available later this month.
. Please complete these steps in order:
1. Download the patched TestComplete build (i think i'm not allowed to share the link)
2. Uninstall the existing TestComplete installation from the machine.
3. Install TestComplete using the file: TestComplete1578_Release_Protected
4. Add the missing required libraries to line 1 of the Python test files that require the use of tc and other module imports:
4.a. from tc import *
Note: Without the " from tc import * " statement, the new interpreter will not discover the TestComplete objects. This is caused by Python 3.12+ enforcing isolated interpreter states. In Python 3.11, global objects injected by the host (so files such as Log, Project, and Sys) could leak across modules. Python 3.12+ prevents this by design. This limitation comes from the Python changes, not from TestComplete.
But I observed another problem with our library Architecture:
With the new python version you can not simply import global python scripts included in your TestComplete project like before.
We use a central library.py that we include in all projects and import it in the test scripts.
There we could add the "from tc import *" simply centralized, BUT:
The new python interpreter only finds scripts located at the project's script directory.
We have to append the path of our global script with sys.path.append() to make it work.
This means a huge amount of hours on our side to make our tests ready for the new TestComplete Version with Python 3.12+.
It's not really a satisfying solution for us but we will probably be left with no other option by SmartBear.