Robotmk missing python module

Hi,

for my Robotmk Testsetup I followed the installation description by Simon Meggle: https://www.simon-meggle.de/tutorial-robotmk-schnellstart-teil-1/ (and part 2). It might be a little outdated, but I guessed it should still work.
When I call the agent the robotmk section displays this:

<<<robotmk>>>
FATAL ERROR!: Robotmk cannot start because of a missing Python3 module (Error was: No module named ‘robot’)
Please execute: pip3 install robotframework pyyaml mergedeep python-dateutil

But these modules are already installed on my Windows Server 2019 Testhost.

> pip3 install robotframework pyyaml mergedeep python-dateutil
Requirement already satisfied: robotframework in c:\program files\python38\lib\site-packages (5.0.1)
Requirement already satisfied: pyyaml in c:\program files\python38\lib\site-packages (6.0)
Requirement already satisfied: mergedeep in c:\program files\python38\lib\site-packages (1.3.4)
Requirement already satisfied: python-dateutil in c:\program files\python38\lib\site-packages (2.8.2)
Requirement already satisfied: six>=1.5 in c:\program files\python38\lib\site-packages (from python-dateutil) (1.16.0)

If I call the plugin directly from the agents plugins directory (robotmk.py) the output displays fine without any missing module problem.

I thought this might be an environment variables problem, since the checkmk service is running as local system user and I would call the plugin as my own (admin) user, but when I call the agent.exe on the host itself, I get the same missing module result (with my user).
Does anyone have a clue, why these modules are seem to be missing, though they are installed?

CMK version: 2.0.0p19 (CEE)
RobotMK version(MPK): v1.2.9

BR
Benjamin

Hi,

as I had the feeling the global installation (and it’s modules) are not considered at all, I used the rule “Install Python runtime environment” and set the “Usage” to “Do not use Checkmk Python, even if it has been installed”.
With this configuration the module(s) are found and the Robotmk plugin works, but I sure this is not meant to be configured this way - I’m not sure if this would break any of the other checks written in python and rely on the shipped version and possibly own modules (if any).

How is this configured correctly?

BR
Benjamin

1 Like

Sorry, I missed this post…
The way @benjamin.alfery describes is correct.
I realize that this is anything but nice. But from the moment checkmk ships its own Python interpreter (for the update plugin), it also tries to run robotmk.py with it instead of using the OS Python for it.
It works the other way around: Python plugins that the agent would normally call with its Python interpreter run without problems with the Python installation of the operating system.

These eternal conflicts with Python interpreters will hopefully be resolved when Robotmk can run the robot tests in isolated RCC environments.

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed. Contact an admin if you think this should be re-opened.