German requires different cases for ‘%s ago’ and ‘%s from now’
还没有人认领这个 Issue。
评估
- 难度
- 4/5
- 预计耗时
- 3-5 天
- 新手友好度
- 35/100
- Issue 类型
- 缺陷
- 描述清晰度
- 基本清楚
- 活跃度
- 停滞
- 技术栈
- python
- 领域
- localization
调研方向
从 src/humanize/time.py 中 naturaldelta() 的输出以及用于“%s ago.”的 i18n 格式字符串附近开始。跟踪过去和将来表达式的德语翻译是如何组装的,然后确定如何表示所需的与格形式,同时不破坏其他 locale。完成的标准是德语的“ago”和“from now”表达式使用正确的格,而现有翻译仍然有效。
由索引模型根据 Issue 内容生成。
描述
This is somewhat related to #88 , but hasn’t been resolved and also needs changes to more than the translation files I am afraid.
So what this is about is that German grammar is a beast, and prepositions require certain cases. For instance, ’vor‘ will need a dativ. ‘an hour ago’ thus translates into ‘vor einer Stunde‘, rather than ‘vor eine Stunde‘ (that’s nominativ).
humanize forms the expression ‘an hour ago‘ by piping the output of naturaldelta straight into the i18n format string for %s ago. naturaldelta() returns a nominativ, that is correct as long as the expression stands by itself. However, as soon as a preposition is placed in front of the value, the grammatical case should change.
(The same is true for ‘in ...’/‘... from now’(which currently translates into ‘... ab jetzt’ which sounds odd). Conveniently, both ‘in’ and ‘vor’ require the same case, dativ)
I would be happy to contribute, but I do not know where to start without breaking things big time. If anybody can give me some directions of how to implement this best, I would go ahead and dig my head in
I don’t properly speak any Slavic languages, but I would expect similar issues with those (correct me if I am wrong)
- 主要语言
- Python
- 星标
- 757
- 派生
- 148
- 平均合并
- 6 天 1 小时
- 30 天内合并 PR
- 12
贡献指南
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
python-humanize/humanize 的其他 Issue
-
难度 2/5 1-3 小时 新手友好度 72/100
python-humanize/humanize#379 ·
-
难度 2/5 1-3 小时 新手友好度 75/100
python-humanize/humanize#366 ·
-
难度 3/5 1-2 天 新手友好度 52/100
python-humanize/humanize#356 · 2 条评论 ·
-
难度 3/5 1-2 天 新手友好度 48/100
python-humanize/humanize#277 · 1 条评论 ·
-
bug
难度 4/5 3-5 天 新手友好度 45/100
python-humanize/humanize#270 · 6 条评论 ·
查看 python-humanize/humanize 的全部 Issue
相似的 Issue
-
Add: hunch 未关闭
难度 2/5 1-3 小时 新手友好度 74/100
AbdelStark/awesome-typesafe#104 ·
-
enhancement
难度 2/5 1-3 小时 新手友好度 72/100
-
难度 2/5 1-3 小时 新手友好度 68/100
DiamondLightSource/dodal#2211 ·
-
难度 2/5 1-3 小时 新手友好度 88/100
openml/openml-python#1749 ·
-
难度 2/5 1-3 小时 新手友好度 88/100
sipyourdrink-ltd/bernstein#6191 ·