NI TestStand

cancel
Showing results for 
Search instead for 
Did you mean: 

TestStand Python Virtual environement Deployment

Solved!
Go to solution

Hi all

 

On my development machine I have installed Python 3.10.11 and added it to the windows environment paths.
In TestStand I configurated the Python Adapter to use a created virtual Environment:

python007_0-1689580759364.png

 

I deployed my Python virtual Environment to a production machine (without installing any Python version, so there is no  python at the windows environment paths!)

I get the fallowing error on the python Adapter on the production machine: "Unknown Python version. TestStand supports Python 3.10, 3.9, 3.8, 3.7. Specify the version with major and minor version number like '1.2'. Make sure Python path is present in PATH environment variable."

python007_2-1689581096110.png

 

Can anyone help me where the problem is?

On the devolpment machine do i have to install a full python Version and not only the Virtual Environemt?

On the devlopment machine do i have to set the windows environment paths to my python virtual environemnt?

 

Best regards

0 Kudos
Message 1 of 4
(998 Views)
Solution
Accepted by python007

As I remember, Python virtual environment always need to have Python installed in anay case. Virtual Env are using the Python run-time only and the vrtual env is giving you a way to control any library available to avoir any crosslink with other configuration.

 

Try to install Python on your deployment machine with option for environment variable set to true.

Maxime R.  

  CLA - Certified LabVIEW Architect / Architecte LabVIEW Certifié
  CTA - Certified TestStand Architect / Architecte TestStand Certifié

0 Kudos
Message 2 of 4
(983 Views)

Hey MaximeR

 

Thanks for your fast answer.

I installed Python on the dployment machine with option for environment variable set to true.

Know TestStand accepts the Virtual Environment without any error.

 

Thats good but I don't really understand why beside the Virtual Environment a Python installation is necessary?

 

 

0 Kudos
Message 3 of 4
(978 Views)

When you install Python you have only the default library and the run-time.

 

You can add some library to Python to add functionnalities. Let's imagine you different projects on your computer and want to use 2 libraries that are compatible together. You don't want to install/uninstall the libraries everytime you want to use the apps.

 

Virtualenv is the way to manage that. You keep the common run-time but install the libraries in a close environment. When you start Python, you says that you want to run it in this particular context and use this library. In this way you can have in different environment you libraries that are not compatible together.

 

But inisde the environment you don't have the run-time. this avoid to duplicate run-time for each application.

 

Hope this help.

Maxime R.  

  CLA - Certified LabVIEW Architect / Architecte LabVIEW Certifié
  CTA - Certified TestStand Architect / Architecte TestStand Certifié

0 Kudos
Message 4 of 4
(961 Views)