Code Monkey home page Code Monkey logo

Comments (19)

mdhiggins avatar mdhiggins commented on May 24, 2024 1

Done, docker containers should be updating and postSonarr.sh should be included

from sonarr-sma.

player666au avatar player666au commented on May 24, 2024

I've modified the script as advised by tscibilia to contain:

/usr/local/sma/env/bin/python3 /usr/local/sma/postSonarr.py "$@"

Still get 'Script exited with code: 255'

This is the total script, one line.

The manual.py script is working fine within the container.

There is a note in the dialog 'Testing will execute the script with the EventType set to Test, ensure your script handles this correctly'. Maybe this is not covered in the script?

from sonarr-sma.

izeen avatar izeen commented on May 24, 2024

I also did this yesterday and have the same problem, i have another exit code tho:
image
image
image

PostSonarr.sh is just:

/usr/local/sma/env/bin/python3 /usr/local/sma/postSonarr.py "$@"

[Error] PostSonarr.sh: Traceback (most recent call last):
sonarr3 | [Error] PostSonarr.sh: File "/usr/local/sma/postSonarr.py", line 22, in
sonarr3 | [Error] PostSonarr.sh: tvdb_id = int(os.environ.get('sonarr_series_tvdbid'))
sonarr3 | [Error] PostSonarr.sh: TypeError: int() argument must be a string, a bytes-like object or a number, not 'NoneType'
sonarr3 | [Warn] SonarrErrorPipeline: Invalid request Validation failed:
sonarr3 | -- : Script exited with code: 1

from sonarr-sma.

player666au avatar player666au commented on May 24, 2024

If you add the test logic early enough in postSonarr.py and, in my case, add #!/bin/bash as the first line in the formerly one line wrapper script, then the Sonarr V3 test finally executes, and then passes, and the script is accepted and the setting can be saved.

from sonarr-sma.

mdhiggins avatar mdhiggins commented on May 24, 2024

Yeah looks like the test setting was accidentally deleted
This has been fixed
I'll start including the .sh script in future docker container updates as well

from sonarr-sma.

player666au avatar player666au commented on May 24, 2024

Thank you!
Ummm... postSonarr.sh needs to be executable or Sonarr is still not happy

from sonarr-sma.

mdhiggins avatar mdhiggins commented on May 24, 2024

Shit I’ll take care of that tonight

from sonarr-sma.

mdhiggins avatar mdhiggins commented on May 24, 2024

Alright should be fixed, the docker containers are rebuilding now

from sonarr-sma.

player666au avatar player666au commented on May 24, 2024

New image, postSonarr.sh is executable!
However, script dialog test button now gives 'Script exited with code: 1'

And as container user abc:
abc@72e97c56f3b0:/$ sonarr_eventtype="Test" /usr/local/sma/postSonarr.sh test
Traceback (most recent call last):
File "/usr/local/sma/postSonarr.py", line 14, in
log = getLogger("SonarrPostProcess")
File "/usr/local/sma/log.py", line 28, in getLogger
fileConfig(configPath, defaults={'logfilename': logPath})
File "/usr/lib/python3.6/logging/config.py", line 84, in fileConfig
handlers = _install_handlers(cp, formatters)
File "/usr/lib/python3.6/logging/config.py", line 148, in _install_handlers
h = klass(*args)
File "/usr/lib/python3.6/logging/handlers.py", line 150, in init
BaseRotatingHandler.init(self, filename, mode, encoding, delay)
File "/usr/lib/python3.6/logging/handlers.py", line 57, in init
logging.FileHandler.init(self, filename, mode, encoding, delay)
File "/usr/lib/python3.6/logging/init.py", line 1032, in init
StreamHandler.init(self, self._open())
File "/usr/lib/python3.6/logging/init.py", line 1061, in _open
return open(self.baseFilename, self.mode, encoding=self.encoding)
PermissionError: [Errno 13] Permission denied: '/var/log/sickbeard_mp4_automator/index.log'

Sorry.

from sonarr-sma.

player666au avatar player666au commented on May 24, 2024

And as root container user, all looks fine from the command line:

root@72e97c56f3b0:/# date
Thu Feb 20 01:30:20 UTC 2020
root@72e97c56f3b0:/# sonarr_eventtype="Test" /usr/local/sma/postSonarr.sh test
2020-02-20 01:30:36 - SonarrPostProcess - INFO - Sonarr extra script post processing started.
root@72e97c56f3b0:/#

from sonarr-sma.

mdhiggins avatar mdhiggins commented on May 24, 2024

Yeah apparently the UID and GID aren't set when I expected during the build process, just pushed some new updates to the containers, rebuilding now but between radarr and sonarr there's 6 tags so the rebuild will take a bit

from sonarr-sma.

player666au avatar player666au commented on May 24, 2024

I can wait. And again, thank you for all this trouble and effort!

from sonarr-sma.

mdhiggins avatar mdhiggins commented on May 24, 2024

No problem, I appreciate the testing let me know if this build works, I'll drop a comment when the sonarr preview build has finished

from sonarr-sma.

mdhiggins avatar mdhiggins commented on May 24, 2024

Should be ready to go

from sonarr-sma.

player666au avatar player666au commented on May 24, 2024

Sorry Micheal, but the set of errors ending with 'PermissionError: [Errno 13] Permission denied: '/var/log/sickbeard_mp4_automator/index.log'' is still there.
This is running as the abc user. Root works.

The Sonarr custom script still shows 'Script exited with code: 1' when the test button is clicked. Processing of media files does not happen.
This is with the 0989abc Commit Source.

from sonarr-sma.

tscibilia avatar tscibilia commented on May 24, 2024

Yeah when i exec into the container, and do an 'ls -al' on the sma directory, the uid is 911 and group id is 1000 despite what is being set by the PUID and PGID variables

EDIT: I did this same and your radarr container displays all files as 'root:root' despite the PUID and PGID set in variables

from sonarr-sma.

mdhiggins avatar mdhiggins commented on May 24, 2024

Trying to find a solution

from sonarr-sma.

mdhiggins avatar mdhiggins commented on May 24, 2024

Alright, after much trial and error and nonsense I think the containers are working

from sonarr-sma.

player666au avatar player666au commented on May 24, 2024

Looks good to me!
Sonarr dialog accepts the script without error, and episodes are being converted.
Thanks!

from sonarr-sma.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.