blacktwin / JBOPS

Just a Bunch Of Plex Scripts
1.67k stars 307 forks source link

Issue #281

Closed fkalmes closed 3 years ago

fkalmes commented 3 years ago

Hello, I reinstall my tautulli server with .exe , i install pynthon (same version 3.8.6) When the script launch i get this error :

2021-01-17 18:32:49 | ERROR | Uncaught exception: Traceback (most recent call last):    File "plexpy\logger.py", line 405, in new_run    File "threading.py", line 870, in run    File "plexpy\notifiers.py", line 3067, in run_scriptUnicodeDecodeError: 'utf-8' codec can't decode byte 0xe9 in position 26: invalid continuation byte
-- | -- | --
2021-01-17 18:32:49 | ERROR | Uncaught exception: Traceback (most recent call last):    File "plexpy\logger.py", line 405, in new_run    File "threading.py", line 870, in run    File "plexpy\notifiers.py", line 3067, in run_scriptUnicodeDecodeError: 'utf-8' codec can't decode byte 0xe9 in position 26: invalid continuation byte
2021-01-17 18:32:49 | DEBUG | Tautulli Notifiers :: Subprocess returned with status code 9009.
2021-01-17 18:32:49 | DEBUG | Tautulli Notifiers :: Subprocess returned with status code 9009.

I tried to run in cmd : python --version and python 3.8.6 is is recognized.

Thank you for your help

Provide logs https://gist.github.com/fkalmes/ecaf2a9b0e340344e1d12a17f76227a5

Desktop

blacktwin commented 3 years ago

Please provide you entire logs. Also what notifier_id is the script? When you reinstalled, did you restore your DB and config.ini files? Did you setup this script agent? Is that script location still valid?

fkalmes commented 3 years ago

the logs https://gist.github.com/fkalmes/83a4d7f39e651e07947c2a79dee23892

I have several scripts :

Capture d’écran 2021-01-18 à 08 50 43 Capture d’écran 2021-01-18 à 08 50 56

When i reinstall Tautulli, i import my tautulli.db. I din't restore config.ini , i just setup again Tautulli. Should have?

I just download the last killstream.py and put it in C:\Program Files\Tautulli\scripts\killstream\kill_stream.py I updated each notification agent script with the good path.

Thanks

blacktwin commented 3 years ago

i install pynthon (same version 3.8.6)

How did you install Python? python.org or Windows Store?

fkalmes commented 3 years ago

python.org yes, i installed the .exe

blacktwin commented 3 years ago

Can you create a simple python script and try to run it using the Test Script button in the Test Notifications section of the agent?

simple script:

import os
import sys
print(sys.prefix)
print(vars(os.environ))

The error code: 9009 suggests that Tautulli can't find Python but as you've provided python is set in PATH.

fkalmes commented 3 years ago

I tested your script the logs

Capture d’écran 2021-01-19 à 21 39 12

Is my path correct if i can see this in cmd?

Capture d’écran 2021-01-19 à 21 35 50

I added

blacktwin commented 3 years ago

You should be seeing a wall of text in your logs when running that script.

fkalmes commented 3 years ago

Maybe i can try to reinstall Tautulli without the .exe?

blacktwin commented 3 years ago

It's not Tautulli, it's your python install.

fkalmes commented 3 years ago

yes but tautulli uses its own version of python with the .exe file, am I Right?

fkalmes commented 3 years ago

SOLVED,

I move my python File from AppData to C:\Program Files, I set the PATH again , restart Tautulli ans everything works like a charm.

Thank you for you time and your amazing scripts ;)

blacktwin commented 3 years ago

Thanks for reporting back with your fix.