blacktwin / JBOPS

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

kill_stream.py - Tab Error #238

Closed fayhal closed 4 years ago

fayhal commented 4 years ago

I have been using the kill_stream script for a while now but have just noticed it has stopped working with the following error:

_Tautulli Notifiers :: Script error: File "/scripts/plexpy/kill_stream.py", line 610 notify(opts, kill_message, 'Paused', tautulli_stream, tautulliserver) ^ TabError: inconsistent use of tabs and spaces in indentation

I use it mainly to stop 4K transcoding and stopping streams playing from 2 different IP addresses, I have not changed anything in the setup I just get the above in the logs?

Thanks.

blacktwin commented 4 years ago

Download the script again and replace what you have.

fayhal commented 4 years ago

Hi,

Thanks for getting back to me I replaced the script as suggested and I get this error in the logs:

_Tautulli Notifiers :: Script error: Traceback (most recent call last): File "/scripts/plexpy/kill_stream_new.py", line 591, in opts = parser.parse_args() File "/app/lib/argparse.py", line 1725, in parse_args args, argv = self.parse_known_args(args, namespace) File "/app/lib/argparse.py", line 1754, in parse_known_args namespace, args = self._parse_known_args(args, namespace) File "/app/lib/argparse.py", line 1960, in _parse_known_args start_index = consume_optional(start_index) File "/app/lib/argparse.py", line 1900, in consume_optional take_action(action, args, option_string) File "/app/lib/argparse.py", line 1812, in take_action argument_values = self._get_values(action, argument_strings) File "/app/lib/argparse.py", line 2249, in _get_values value = self._get_value(action, arg_string) File "/app/lib/argparse.py", line 2278, in _get_value result = type_func(arg_string) File "/scripts/plexpy/kill_stream_new.py", line 105, in arg_decoding return arg.decode(TAUTULLIENCODING).encode('UTF-8') AttributeError: 'str' object has no attribute 'decode'

This error is when the same user tries to play 2 streams from 2 different locations.

Thanks.

blacktwin commented 4 years ago

Sorry you need to download it from the Python3 branch.

fayhal commented 4 years ago

Thanks, the script from the Python3 branch has worked.