Pipe Is Broken Error When Running A Python Script As A Background Process

Experiencing difficulties with running a Python script as a background process, specifically encountering a 'Pipe is broken' error.

Issue Description:

Users may encounter a 'Pipe is broken' error when running a Python script as a background process. While the script functions correctly in the foreground, it fails when operated in the background. This issue is likely a result of visibility issues with Python modules.

Resolution:

If the problem persists, setting the environment variable UIPATH_HEADLESS_WITH_USER to True has been found to resolve this issue. This solution allows the background process to access the required Python modules.

Resolution Instructions:

  1. Set the environment variable UIPATH_HEADLESS_WITH_USER to True on the robot machine.

  2. Reboot the robot machine to ensure the environment variable takes effect.

  3. Verify the Python script is now running successfully as a background process.

By following these instructions, users should be able to recover from the 'Pipe is broken' error when executing Python scripts in the background.