diff --git a/chameleonultragui/lib/l10n/updateCrowdin.py b/chameleonultragui/lib/l10n/updateCrowdin.py index 0ab5746b..378f4812 100644 --- a/chameleonultragui/lib/l10n/updateCrowdin.py +++ b/chameleonultragui/lib/l10n/updateCrowdin.py @@ -26,11 +26,12 @@ def request(method, url, data=None): 'Content-Type': 'application/json'})).read().decode()) def add_string_to_source(string): + print(string) projectId = 611911 sourceId = 33 try: - string_parsed = string.split('+++ chameleonultragui/lib/l10n/app_en.arb ', 1)[1].replace(' ', '').replace(',', '').replace('\n','').split('+')[1:] + string_parsed = string.split('app_en.arb', 1)[1].replace(' ', '').replace(',', '').replace('\n','').split('+')[1:] for s in string_parsed: data = {'identifier': key.replace('"', ''), 'text': value.replace('"', ''), 'fileId': sourceId} try: @@ -40,7 +41,7 @@ def add_string_to_source(string): except Exception as e: print(e) - except: + except Exception as e: print(e) if __name__ == "__main__":