Currency: some symbols aren't recognized as `mo`, and "200 €" in one `mn` is singular
メンテナーはふだん 1 日以内に返信
まだ誰も着手していません。
評価
- 難易度
- 4/5
- 見積もり時間
- 3〜5日
- 初心者へのやさしさ
- 48/100
- issue の種類
- バグ
- 明瞭さ
- おおむね明確
- 活発さ
- 活発
- 技術スタック
- rust
- 領域
- accessibility, backend
調査の方向性
Start with src/canonicalize.rs and inspect the fixed currency symbol list and the handling of symbols inside mn tokens. Then trace the currency rules and UnitNumber behavior for the English and Spanish examples, and find the related tests before changing anything. Done means the listed symbol and amount cases produce the expected speech, with the decimal question resolved by the relevant behavior and tests.
索引モデルが issue の本文から書いたものです。
説明
Found while checking Spanish currencies (examples in English unless noted).
1. Symbols missing from is_currency_symbol. src/canonicalize.rs has a fixed list, so ¥, ₲, ₽ and ₴ written as <mo> aren't treated as currency:
| input | speech | expected |
|---|---|---|
<mo>¥</mo><mn>200</mn> |
yen 200 | 200 yen |
<mn>200</mn><mo>¥</mo> |
200 yen | 200 yen (es: 200 yenes) |
<mo>₲</mo><mn>200</mn> |
guaranis 200 | 200 guaranis |
<mo>₽</mo><mn>200</mn> |
₽ 200 | 200 rubles |
With <mi> they work when the language lists them in CurrencySymbols. Maybe is_currency_symbol could use the language's CurrencySymbols instead of a fixed list; otherwise, adding ¥ ₲ ₽ ₴ would cover these.
2. Amount and symbol in one mn. <mn>200 €</mn> is split into <mn>200 </mn> <mi>€</mi>: an extra invisible times at the start and a trailing space in the number. Then the currency rules don't match:
| input | en | es |
|---|---|---|
<mn>200 €</mn> |
200 euros | 200 euro |
<mn>1 €</mn> |
1 euros | 1 euro (should be "un euro") |
<mn>€200</mn> |
200 euros | 200 euros |
3. A small question. <mn>1,0</mn><mo>€</mo> in Spanish says "un euro"; with decimals Spanish normally uses the plural ("1,0 euros"), as English does ("1.0 euros"). Is UnitNumber meant to treat 1,0 as "one"?
- 主要言語
- Rust
- スター
- 131
- フォーク
- 97
- 平均マージ
- 21時間 45分
- マージ済み PR(30日)
- 95
環境構築
- Dockerfile・Docker Compose ファイルなし
- プルリクエストのテンプレートなし
- コントリビューションガイドを読む
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
daisy/MathCAT のほかの issue
-
難易度 2/5 1〜3時間 初心者へのやさしさ 76/100
メンテナーはふだん 1 日以内に返信
-
難易度 1/5 1時間未満 初心者へのやさしさ 84/100
メンテナーはふだん 1 日以内に返信
-
難易度 1/5 1時間未満 初心者へのやさしさ 88/100
メンテナーはふだん 1 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 82/100
メンテナーはふだん 1 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 88/100
メンテナーはふだん 1 日以内に返信
似ている issue
-
area:schema documentation
難易度 2/5 1〜3時間 初心者へのやさしさ 76/100
メンテナーはふだん 1 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 82/100
ElectronicWave/Elemental#252 ·
メンテナーはふだん 1 日以内に返信
-
bug
難易度 2/5 1〜3時間 初心者へのやさしさ 78/100
dekobon/big-code-analysis#1887 ·
メンテナーはふだん 1 日以内に返信
-
Shell中文符号输入异常オープンbug
難易度 2/5 1〜3時間 初心者へのやさしさ 76/100
メンテナーはふだん 1 日以内に返信
-
難易度 1/5 1時間未満 初心者へのやさしさ 82/100
メンテナーはふだん 1 日以内に返信