Video Capture of Robot run


If you need to record a video of your Robot run, you can try using -library. It may be useful e.g. for debugging failed Robot runs.

An example Robot and -library are available in GitHub - robocorp/example-screen-recording

To use it with your own Robot, you must copy to the Robot directory and add python-mss, numpy and opencv dependencies to conda.yaml:

  - defaults
  - conda-forge
  - python=3.7.5
  - pip=20.1
  - python-mss
  - numpy
  - opencv
  - pip:
    - rpaframework==7.*

tasks.robot contains an example of using video recording. It stores the recording to the Robocorp Cloud. It is easy to modify it to store the video only if Robot Framework execution FAILs - for debugging purposes.

Library should work in Windows, MacOS and Linux. NOTE that recording does not work with Robocorp Cloud container as it doesn’t have a desktop. Recording would require a container with xvfb or similar.


This is great @Teppo, thanks for this comment here. I didn’t know it was possible