External Python librariesΒΆ

The installation folder is set in the directory settings, see External Python libraries. The python libraries it contains are available in ecu.test for the user.

../_images/Einstellungen_Python-Bibliotheken.png

It is recommended to specify additional Python libraries in a requirements.txt file and install them via ecu.test to avoid conflicts to the shipped with libraries.

Further information for the syntax of the requirements.txt can be found in the pip documentation. With the option Use the requirements.txt the installation takes into account the requirements.txt and can be manually started with the button Install. The button Show in file manager opens the directory with the requirements.txt and creates a new file if no one exists.

During the installation the given Python libraries are compared to the libraries shipped with ecu.test and only additional libraries without conflicts are installed. The timeout is valid for a single pip call (several pip calls are needed for one installation process).

If a Python library needs to be built locally, then it may be necessary to consider the installation instructions of the specific library (e.g. provide additional compilers).

The file resolved_requirements_<sys_platform>_<platform_machine>.txt in the installation directory lists all additionally installed Python libraries. Since this file (unlike requirements.txt) is platform-specific, platform information is encoded in the filename. Conflicts during dependency resolution are written to the log.

An automatic installation at program start of ecu.test is triggered by using the option Install at program start. Alternatively, installation can be triggered via command line. See Installing external Python libraries via command line for details.

The installation takes into account the usual pip config files. In addition a pip.ini file in WORKSPACE/.workspace can be configered. During the installation the environment variable PIP_CONFIG_FILE is used to hand over the path of the config file to the pip call. A user-defined path using this environment variable is not considered, if a pip.ini file exists in WORKSPACE/.workspace.

The library overview placed below shows the libraries (respectively directories) installed in the library directory at the moment.

These settings are stored in the file pythonlibrary.xml.