Skip to content

Fixes #559 by Paola L. & Sydney F.#633

Open
sydneyfi wants to merge 2 commits intosavoirfairelinux:masterfrom
sydneyfi:new-branch
Open

Fixes #559 by Paola L. & Sydney F.#633
sydneyfi wants to merge 2 commits intosavoirfairelinux:masterfrom
sydneyfi:new-branch

Conversation

@sydneyfi
Copy link
Copy Markdown

Fixes #559 by Paola L. & Sydney F.

Changes proposed in this pull request:

  • Added a fallback return to the merge() method in lang_am.py to ensure it always returns a (text, number) tuple.
    Fixed a bug where certain numbers like 1210 would cause a TypeError: cannot unpack non-iterable NoneType object.
    Added new unit tests to check that num2words can safely handle numbers like 1210, 1_000_000, and 1_000_000_000 in Amharic without raising errors.

Status

  • READY
  • HOLD
  • WIP (Work-In-Progress)

How to verify this change

Run the full Amharic language unit tests:
python3 -m unittest tests/test_am.py
Confirm that no TypeError is raised when converting numbers such as 1210, 1000000, and 1000000000 using num2words(lang="am"). Confirm that all tests pass successfully, indicating that numbers are now handled safely in the Amharic language module.

Additional notes

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants