✨ Use of var-args makes translation to other languages difficult
See original GitHub issueIs there an existing issue for this?
- I have searched the existing issues
Suggestion
There seems to be some inconsistent use of varargs in a few places that make the translation to other languages more difficult than it needs to be. The example I’ve come across is https://github.com/microsoft/electionguard-python/blob/main/src/electionguard/ballot.py#L757 which has the lines
contest_hashes = [contest.crypto_hash for contest in self.contests]
return hash_elems(self.object_id, encryption_seed, *contest_hashes)
Possible Implementation
The code above could easily just be simply
contest_hashes = [contest.crypto_hash for contest in self.contests]
return hash_elems(self.object_id, encryption_seed, contest_hashes)
which should achieve the same outcome but make translations easier when languages don’t have things like heterogeneous lists. In my Haskell implementation, hashes of multiple arguments of differerent are represented using the instances for various tuple types, so I can’t generate a tuple of arbitrary size at runtime.
Anything else?
No response
Issue Analytics
- State:
- Created 2 years ago
- Comments:9
Top Results From Across the Web
5 Toughest Languages to Translate into any Language Pair
The wide vocabulary of the Arabic language makes it difficult to translate. It is one of the other languages where words can have...
Read more >Top 5 Toughest Languages To Translate - Localize Blog
The use of multiple homophones, idioms, and aphorisms makes Mandarin one of the most difficult languages for English speakers to grasp.
Read more >What Makes Translation So Difficult?
The best translations are produced by humans. Translation can also be difficult because of cultural differences. Words often reflect the ...
Read more >9 Things That Make Language Translation Difficult
Languages keep evolving. Language systems differ. Translation is complex. Here are nine things that make language translation difficult.
Read more >The Top 5 Hardest Languages to Translate - Acutrans
When it comes to translations, many people assume that all languages are equally challenging. However, that isn't actually the case.
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found

This is a great distinction to make for transliteration. Let’s leave this in
triagebut expand a bit more to denote all the lines where this is true.This feature won’t be worked on despite the value of transliteration because we want to make sure the hashes are as flat as possible going for.