From 4f996e4f2ebd0a8dceaff1ea9582a5b2a83bbe44 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Louis=20V=C3=A9zina?= <5130500+morpheus65535@users.noreply.github.com> Date: Sat, 7 Dec 2019 12:53:40 -0500 Subject: [PATCH] Fix for 'BrokenPipeError' is not defined under Python 2.7.x. --- bazarr/main.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/bazarr/main.py b/bazarr/main.py index 88b0d89c0..696bc6f68 100644 --- a/bazarr/main.py +++ b/bazarr/main.py @@ -2251,7 +2251,9 @@ def api_help(): # Mute DeprecationWarning -warnings.simplefilter("ignore", (DeprecationWarning, BrokenPipeError)) +warnings.simplefilter("ignore", DeprecationWarning) +if six.PY3: + warnings.simplefilter("ignore", BrokenPipeError) server = CherryPyWSGIServer((str(settings.general.ip), (int(args.port) if args.port else int(settings.general.port))), app) try: logging.info('BAZARR is started and waiting for request on http://' + str(settings.general.ip) + ':' + (str(