• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

jqueguiner / num2words2
95%
main: 95%

Build:
Build:
LAST BUILD BRANCH: feat/sentence-multilang-ordinals
DEFAULT BRANCH: main
Repo Added 17 Jan 2026 05:49PM UTC
Token Bt3d6ZRNkMfP1R29FrGOxHISSecLQRVXP regen
Build 375 Last
Files 339
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

LAST BUILD ON BRANCH v1.0.12
branch: v1.0.12
CHANGE BRANCH
x
Reset
Sync Branches
  • v1.0.12
  • add-26-missing-languages
  • add-croatian-language-support-v2
  • add-greek-language-support-v2
  • automated-pypi-publishing
  • ci/add-python-3.14-3.15
  • ci/auto-release-notes
  • ci/camo-cache-purge
  • ci/credit-contributors
  • ci/improve-coverage
  • docs/comprehensive-reference
  • feat/256-364-3decimal-cheque
  • feat/478-aviation-phraseology
  • feat/478-aviation-service-profiles
  • feat/478-en-aero
  • feat/584-fractions
  • feat/sentence-multilang-ordinals
  • fix/478-icao-strict-digits
  • fix/603-decimal-precision
  • fix/ar-e2e-stale-comma
  • fix/aur-ssh-key-newline
  • fix/lint-coverage-exhaustive
  • fix/tr-correctness-487-128
  • fix/upstream-313-en_in-default-inr
  • fix/upstream-431-425-cz-dk-aliases
  • fix/upstream-476-id-str-to-number
  • fix/upstream-483-ru-default-rub
  • fix/upstream-560-uk-gender
  • fix/upstream-573-sv-triple-t
  • fix/upstream-591-am-stray-m
  • force-test-run
  • main
  • master
  • port/upstream-293-id-constants
  • port/upstream-314-romansh
  • port/upstream-370-sv-fyrtio
  • port/upstream-383-uz-cyrl
  • port/upstream-451-dhivehi
  • port/upstream-467-es-crc
  • port/upstream-499-ro-mega-de
  • port/upstream-517-en-large-numbers
  • port/upstream-538-ar-lbp
  • port/upstream-548-en-np
  • port/upstream-556-ko-ordinal
  • port/upstream-559-ru-gender
  • port/upstream-563-ar-yer-usd
  • port/upstream-586-es-hn
  • port/upstream-588-kn-cardinal
  • port/upstream-612-it-currencies
  • port/upstream-613-de-currencies
  • port/upstream-614-fr-currencies
  • port/upstream-615-pt-currencies
  • port/upstream-620-ligurian
  • port/upstream-632-it-diciotto
  • port/upstream-642-nl-duizend
  • port/upstream-652-en-ne
  • port/upstream-654-en-in-crore
  • track-missing-languages
  • v1.0.1
  • v1.0.10
  • v1.0.11
  • v1.0.13
  • v1.0.14
  • v1.0.15
  • v1.0.16
  • v1.0.17
  • v1.0.2
  • v1.0.9

01 May 2026 02:11PM UTC coverage: 95.27% (-0.01%) from 95.281%
25217503490

push

github

web-flow
feat(currency): 3-decimal mils + bank cheque format (#112)

Two upstream feature requests, shipped together because they share the
same per-currency precision plumbing:

#256 — 3-decimal currencies (savoirfairelinux/num2words#256)
  Currencies with 1000-mil subunits (BHD, KWD, OMR, JOD, TND, LYD, IQD)
  now round-trip cleanly through to_currency. Driven by:
    - parse_currency_parts gains a `divisor` parameter (defaults 100)
    - Num2Word_Base.CURRENCY_PRECISION class map; per-currency override
    - to_currency reads the divisor and quantizes accordingly
    - Zero-decimal currencies (JPY/KRW are kept at default 100 to
      preserve historical sen/jeon test fixtures; the divisor=1 path
      exists for callers who want round-to-whole-unit explicitly)

  Examples:
    num2words(5.123, currency='BHD')  # 'five dinars, one hundred and twenty-three fils'
    num2words(0.001, currency='TND')  # 'zero dinars, one millime'

#364 — bank cheque format (savoirfairelinux/num2words#364)
  New `to='cheque'` mode emits the standard banking style:
    "ONE THOUSAND, TWO HUNDRED AND THIRTY-FOUR AND 56/100 DOLLARS"
  Combines:
    - integer part as cardinal words
    - " AND " connector
    - fractional subunit as digits/divisor (e.g. 56/100, 234/1000)
    - currency name in plural (cheque convention always pluralises)
    - whole result upper-cased

  Composes cleanly with #256: a BHD cheque ends "234/1000 DINARS".

Tests live in tests/test_currency_3decimal_and_cheque.py covering all
seven mil currencies, integer / float / negative inputs, plural-form
edge cases, and the unknown-currency raise.

Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com>

7946 of 8706 branches covered (91.27%)

Branch coverage included in aggregate %.

101 of 107 new or added lines in 5 files covered. (94.39%)

41962 of 43680 relevant lines covered (96.07%)

5.76 hits per line

Relevant lines Covered
Build:
Build:
43680 RELEVANT LINES 41962 COVERED LINES
5.76 HITS PER LINE
Source Files on v1.0.12
  • Tree
  • List 334
  • Changed 4
  • Source Changed 0
  • Coverage Changed 4
Coverage ∆ File Lines Relevant Covered Missed Hits/Line Branch Hits Branch Misses

Recent builds

Builds Branch Commit Type Ran Committer Via Coverage
25217503490 v1.0.12 feat(currency): 3-decimal mils + bank cheque format (#112) Two upstream feature requests, shipped together because they share the same per-currency precision plumbing: #256 — 3-decimal currencies (savoirfairelinux/num2words#256) Currencies wit... push 01 May 2026 02:12PM UTC web-flow github
95.27
See All Builds (162)

Badge your Repo: num2words2

We detected this repo isn’t badged! Grab the embed code to the right, add it to your repo to show off your code coverage, and when the badge is live hit the refresh button to remove this message.

Could not find badge in README.

Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

Refresh
  • Settings
  • Repo on GitHub
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc