|
|
|
@ -103,6 +103,11 @@ def download_subtitle(path, language, hi, providers, providers_auth, sceneName,
|
|
|
|
|
# fixme: supply all missing languages, not only one, to hit providers only once who support multiple languages in
|
|
|
|
|
# one query
|
|
|
|
|
|
|
|
|
|
if settings.general.getboolean('utf8_encode'):
|
|
|
|
|
os.environ["SZ_KEEP_ENCODING"] = ""
|
|
|
|
|
else:
|
|
|
|
|
os.environ["SZ_KEEP_ENCODING"] = True
|
|
|
|
|
|
|
|
|
|
logging.debug('BAZARR Searching subtitles for this file: ' + path)
|
|
|
|
|
if hi == "True":
|
|
|
|
|
hi = "force HI"
|
|
|
|
@ -329,6 +334,11 @@ def manual_search(path, language, hi, providers, providers_auth, sceneName, titl
|
|
|
|
|
def manual_download_subtitle(path, language, hi, subtitle, provider, providers_auth, sceneName, title, media_type):
|
|
|
|
|
logging.debug('BAZARR Manually downloading subtitles for this file: ' + path)
|
|
|
|
|
|
|
|
|
|
if settings.general.getboolean('utf8_encode'):
|
|
|
|
|
os.environ["SZ_KEEP_ENCODING"] = ""
|
|
|
|
|
else:
|
|
|
|
|
os.environ["SZ_KEEP_ENCODING"] = True
|
|
|
|
|
|
|
|
|
|
subtitle = pickle.loads(codecs.decode(subtitle.encode(), "base64"))
|
|
|
|
|
use_scenename = settings.general.getboolean('use_scenename')
|
|
|
|
|
use_postprocessing = settings.general.getboolean('use_postprocessing')
|
|
|
|
|