XML::Simple error, only when running via crontab

I have what seems like a strange problem. I'm running on Linux and have followed the manual installation instructions and have the PVR setup to run via crontab. Everything was fine until a few days ago when I noticed that nothing was downloading so checked the logs and saw the XML:Simple error mentioned in the 2.94 update. Updated to 2.94 and still the same problem. I checked and have XML::Simple installed (installed via local::lib). I ran the PVR manually and everything worked - the error only seems to happen when running via crontab. I tried making a script to run the PVR, with the eval `perl -I ~/perl5/lib/perl5 -Mlocal::lib' line at the start of the script, in case it was an environment issue when running via cron, but still the same error.

Any ideas at all on what could be the issue? I can run it manually but obviously it is not as convenient so if I can get it back up and running via cron it would be great!

You need to see the output from
perl -I ~/perl5/lib/perl5 -Mlocal::lib
under cron. It's possible cron is running as root and you set up local::lib under your personal account. You shouldn't use local::lib unless absolutely necessary, though. What distro do you use?
Sorry for the delay in getting back about this. I don't have root access where I was running it so I had to run it using local::lib. Thanks for the advice, it definitely was the account/environment in which cron was running, so I solved it by running get_iplayer using 'Perl -I', so:

perl -I /location/of/local/perl/lib get_iplayer --pvr

That seemed to do the trick. Just thought that I would post how I solved it in case anyone else has a similar issue.

Possibly Related Threads…
Thread Author Replies Views Last Post
  Cannot find Perl local lib from crontab az_49 2 3,460 23-06-2017, 07:18 PM
Last Post: az_49
  "Run PVR" not actually running anything jsiddall 9 7,756 01-03-2014, 09:31 PM
Last Post: nacronoolidge