fallingdog

Can not access network location from Task Scheduler python

Discussion created by fallingdog on Aug 6, 2015
Latest reply on Nov 2, 2015 by bixb0012

I have some code that runs fine when I am running it logged in. However, when I run it from task scheduler it fails. It is failing on the first line that points to a network drive.

 

os.listdir(path)

 

  • The code uses UNC paths
  • Task scheduler is set to run if the user is logged on or not
  • The task is set to run with the highest privileges
  • The run result is (0x1)
  • Bat files run from task scheduler work  fine when pointing to the network location, e.g. robocopy, RD, MD
  • Python run from a bat file works fine with the network drives

 

Does anyone know why this is happing?

 

Thanks,

 

Forest

Outcomes