Forum Discussion

tc_2018's avatar
tc_2018
Contributor
5 years ago
Solved

TestCompete closes unexpectedly when trying to import Pandas

I got an unexpected behavior of TestComplete. 

What I am trying to do is to import pandas.

With the code below, it runs ok for the first time; however, when I run the second time, TestComplete just closes.

Do you have any idea?

Thanks.

 

 

import os

import sys

def testImportPandas():

 

    sys.path.insert(0, 'C:\Program Files\Python36\Lib\site-packages') 

 

    import pandas as pd

   

    curDir = os.getcwd() #NOTE: Break point was set and it never stops here when running the second time.

    Log.Message(curDir)

    fileName = os.path.join(curDir,"ExcelFiles", "MyFile.xls" )

    Log.Message(fileName)

    ...

2 Replies