Error trying to run post-processing script. Unable to send OnDownload notification...Native error= Access denied

Sonarr version (exact version): 2.0.0.5301
Mono version (if Sonarr is not running on Windows): 5.16.0
OS: unRAID 6.6.6, binhex-sonarr docker
Debug logs: https://drive.google.com/open?id=1eHiR5_TbNFgLBOXFD7yRJx4ZFZOzWJxw [Error occuring is at the bottom]
Description of issue: Unable to send OnDownload notification to: lcextractor_cleanup: ApplicationName=’/scripts/lcextractor_cleanup.py’, CommandLine=’’, CurrentDirectory=’’, Native error= Access denied

Trying to run a python script that cleans up extracted files after import. However, sonarr is giving me an error that I’m not sure how to understand/fix.

I’m using the LCExtractor plugin for Deluge, with the LC_extractor Cleanup script, set to run “On Download” and “On Upgrade”. I followed the instructions for the script for modifying deluge url/password. The only thing I wasn’t sure on in the README instructions was " Ensure script is executable and set correct shebang for your environment".

LCExtractor Cleanup github here: https://github.com/levic92/LCExtractor/tree/master/extras

My docker permissions give Sonarr read/write access to /data as well as /media, I initially was storing the script in /scripts instead of /data, and tried moving it to /data but still was getting the same error.

My LCExtractor plugin is set to extract the file in place inside the torrent folder.

Is this just a limitation of using Sonarr in a Docker?
Similar issue I found on the LCExtractor github: https://github.com/levic92/LCExtractor/issues/23

EDIT: If anyone comes across this looking for extra help. I did manage to solve cleaning up files, but with a different script :slight_smile: , https://gist.github.com/fryfrog/94716e7e27ba38dff57c7631d9f58bed

Is the script executable for the user running Sonarr?

How would I check this? The only user on my unRAID server is root. And, Sonarr successfully “tests” the script in the settings.

I also had the same issue running a different script that would perform the same purpose, however that one was a Shell Script.

Check the permissions of the file.

That only checks that the file is present.

Ok, I went into the security settings on the file through Windows, and enabled Read & Execute for all the listed users, which somewhat helped, now I’m getting a different error from the script and the extracted file still isn’t being cleaned up. It spit this log file out into the script folder

Full Sonarr log

That’s the script itself throwing an error.

That’s what I assumed, I guess this is closed from a Sonarr perspective then. Thanks for the help.

This topic was automatically closed 60 days after the last reply. New replies are no longer allowed.