From 5033f58e0daa3a9d612d8b4e99d686ed4edb4391 Mon Sep 17 00:00:00 2001 From: Piero Toffanin Date: Mon, 30 Oct 2023 13:23:16 -0400 Subject: [PATCH] Handle zt lingua case --- libretranslate/detect.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/libretranslate/detect.py b/libretranslate/detect.py index a0b15b2..2fd1d6e 100644 --- a/libretranslate/detect.py +++ b/libretranslate/detect.py @@ -16,6 +16,8 @@ class Language: def load_detector(langcodes = ()): languages = [] for lc in langcodes: + if lc == 'zt': + continue try: languages.append(linguars.Language.from_iso_code_639_1(lc)) except Exception: