Issues running Robot Test cases on Jenkins

Hi

I have a working Robot framework set up with robot test cases running successfully on pycharm. However when i execute the test cases from jenkins(local host) after installing robot framework plugin i see this error “ModuleNotFoundError: No module named ‘robot’”
Here is my console output. Can someone please help set this up right?

Batch command
cd C:\Users\ez93380\Documents\BellProject\Automation\WebCareWithoutVEnv
echo %PYTHONPATH%
echo %ROBOTPATH%
robot --loglevel TRACE TestCases.robot

Console log


Running as SYSTEM
Building in workspace C:\Program Files\Jenkins\workspace
[workspace] $ cmd /c call C:\WINDOWS\TEMP\jenkins14008655606543891715.bat

C:\Program Files\Jenkins\workspace>cd C:\Users\ez93380\Documents\BellProject\Automation\WebCareWithoutVEnv

C:\Users\ez93380\Documents\BellProject\Automation\WebCareWithoutVEnv>echo C:\Users\ez93380\Documents\BellProject\Automation\WCVirtual\VenvWCVirtual\Scripts;C:\Users\ez93380\AppData\Roaming\Python\Python39\Scripts;C:\Users\ez93380\Documents\BellProject\Automation\WCVirtual;C:\Users\ez93380\AppData\Roaming\Python\Python39;C:\Program Files\Python39;C:\Program Files\Python39\Scripts;C:\Program Files\Python39\Lib\site-packages;
C:\Users\ez93380\Documents\BellProject\Automation\WCVirtual\VenvWCVirtual\Scripts;C:\Users\ez93380\AppData\Roaming\Python\Python39\Scripts;C:\Users\ez93380\Documents\BellProject\Automation\WCVirtual;C:\Users\ez93380\AppData\Roaming\Python\Python39;C:\Program Files\Python39;C:\Program Files\Python39\Scripts;C:\Program Files\Python39\Lib\site-packages;

C:\Users\ez93380\Documents\BellProject\Automation\WebCareWithoutVEnv>echo
ECHO is on.

C:\Users\ez93380\Documents\BellProject\Automation\WebCareWithoutVEnv>robot --loglevel TRACE TestCases.robot
Traceback (most recent call last):
File “c:\program files\python39\lib\runpy.py”, line 197, in _run_module_as_main
return _run_code(code, main_globals, None,
File “c:\program files\python39\lib\runpy.py”, line 87, in run_code
exec(code, run_globals)
File "C:\Program Files\Python39\Scripts\robot.exe_main
.py", line 4, in
ModuleNotFoundError: No module named ‘robot’

C:\Users\ez93380\Documents\BellProject\Automation\WebCareWithoutVEnv>exit 1
Build step ‘Execute Windows batch command’ marked build as failure
Finished: FAILURE

This is a Jenkins question and not a JenkinsX one. So best to ask in Jenkins forums.

ModuleNotFoundError: No module named ‘robot’

I am not sure how exporting environment variables work with windows, but in our linux build systems we have something like this (which works):

export PYTHONPATH=$PYTHONPATH:$PWD/src:$PWD/test:/usr/local/lib/python3.8/dist-packages
and then run the python commands.
or you can do PYTHONPATH=$PYTHONPATH:$PWD/src:$PWD/test:/usr/local/lib/python3.8/dist-packages python script.py

Thank you. i tried searching the web a lot for Jenkins forums. if you know of any popular forums could you please share?