cancel
Showing results for 
Search instead for 
Did you mean: 

How to download and add external Python packages in TC 14

SOLVED
Contributor

How to download and add external Python packages in TC 14

Hello All,

 

Can anyone suggest me step by step process to download and add external Python packages in TC 14. 

 

I tried the following, but I didn't have any luck

https://support.smartbear.com/testcomplete/docs/scripting/specifics/python.html

 

from os import sys
sys.path.insert(0, '%PATH_TO_PYTHON_DIRECTORY%\Lib\site-packages') import requests #--> getting error i.e. requests module doesn't found

 

And do I need to install python in my machine? I guess python is inbuilt  with TC . Am i right?

 

-BommaReddy

1 ACCEPTED SOLUTION

Accepted Solutions
Highlighted
Community Hero

Re: How to download and add external Python packages in TC 14

Python has a specific install in TestComplete that TestComplete uses to run.

This requests package.  Is it part of Python? Is it custom?  

In order for TestComplete to find the package, it needs to be placed in the specific TestComplete folder (see https://support.smartbear.com/testcomplete/docs/scripting/specifics/python.html#importing-packages).  If you don't have it there, it can't find the module.


Robert Martin
[Community Expert Group]
Please consider giving a Kudo if I write good stuff
----

Why automate?  I do automated testing because there's only so much a human being can do and remain healthy.  Sleep is a requirement.  So, while people sleep, automation that I create does what I've described above in order to make sure that nothing gets past the final defense of the testing group.
I love good food, good books, good friends, and good fun.

Mysterious Gremlin Master
Extensions available
4 REPLIES 4
Highlighted
Community Hero

Re: How to download and add external Python packages in TC 14

Python has a specific install in TestComplete that TestComplete uses to run.

This requests package.  Is it part of Python? Is it custom?  

In order for TestComplete to find the package, it needs to be placed in the specific TestComplete folder (see https://support.smartbear.com/testcomplete/docs/scripting/specifics/python.html#importing-packages).  If you don't have it there, it can't find the module.


Robert Martin
[Community Expert Group]
Please consider giving a Kudo if I write good stuff
----

Why automate?  I do automated testing because there's only so much a human being can do and remain healthy.  Sleep is a requirement.  So, while people sleep, automation that I create does what I've described above in order to make sure that nothing gets past the final defense of the testing group.
I love good food, good books, good friends, and good fun.

Mysterious Gremlin Master
Extensions available
Contributor

Re: How to download and add external Python packages in TC 14

How can I download "requests" module/package in Test Complete.

 

Once downloaded, i can place it in the specified folder.  I am unable to download that package.

Community Hero

Re: How to download and add external Python packages in TC 14

That sounds like a question for your own IT/IS department.  TestComplete doesn't have anything to do with the specific modules, you'll need to get the module into the folder however you can download it.


Robert Martin
[Community Expert Group]
Please consider giving a Kudo if I write good stuff
----

Why automate?  I do automated testing because there's only so much a human being can do and remain healthy.  Sleep is a requirement.  So, while people sleep, automation that I create does what I've described above in order to make sure that nothing gets past the final defense of the testing group.
I love good food, good books, good friends, and good fun.

Mysterious Gremlin Master
Extensions available
Community Manager

Re: How to download and add external Python packages in TC 14

Hi @bommareddy,

Were you able to resolve the question?  What was the solution?

---------
Tanya Gorbunova
SmartBear Community Manager

Did my reply answer your question? Give Kudos or Accept it as a Solution to help others.↓↓↓↓↓
New Here?
Join us and watch the welcome video:
Top Kudoed Authors