Save Image throws NullReference Exception

How to troubleshoot post upgrading from 2017.1 to 2018.2.3, a workflow throws "Save Image :System.NullReferenceException: Object reference not set to an instance of an object" error?

Post upgrading from 2017.1 to 2018.2.3 one of the existing workflow which was working earlier, throws error "Save Image :System.NullReferenceException: Object reference not set to an instance of an object". 

And this error doesn't happen if the workflow is run directly from the Robot machine.

Troubleshooting Steps

[Below are some of the reasons identified]

  1. If selectors for Take screenshot activity are used, then remove the selectors and attempt again
  2. Also try to add some 2-3 mins delay in between Take Screenshot and Save Image activities and verify

Version: When upgrading from 2017.x to 2018.2.3