Closed unreadableusername closed 9 months ago
@unreadableusername I think the note on target_lang
- "EN - English (unspecified variant for backward compatibility; please select EN-GB or EN-US instead)" is fairly clear. We should follow the advised approach. Do you have the capacity to submit a PR?
You'll get me started on a rant about EN being taken to mean EN-US when US English is a dialect of English only used in parts of North America 😂. European (and more) sites that use EN mean international English which definitely is not US English. It's a bit like using FR and getting Quebecois instead.
I've always thought there should be a configurable default locale when using language codes. Having to specify something like EN-GB in the url to get non-American English makes no sense and makes the reader it's something UK specific.
Added tests and merged in a3efa8f Thank you
The DeepL API documentation specifies to use EN-GB or EN-US to archieve the desired translation, however following code in the deepl.py will chop off the -GB or -US and the deprecated unspecified route will be used.
I suggest to add en-gb and en-us to the array inside the if statement above to respect users desired locale setting. Please tell me if this is shortsightet or more complicated then this 😅