Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Some currencies have other than 100 fractional units; and fractional units all are named "cents" in English #17

Closed
pavloslav opened this issue Nov 27, 2023 · 2 comments
Assignees
Milestone

Comments

@pavloslav
Copy link
Contributor

pavloslav commented Nov 27, 2023

According to Wiki, there are some currencies that are split in other number of fractions, like BHD (1000) or BND (10). Even Yuan is split into 10 Jiao, not 100. Sometimes currencies that have the same name have the different number of fractions, like Iraqi dinar (IQD) has 1000 Fils, and Serbian dinar (RSD) has 100 Para. There should be an additional argument in to_currency function.

Also, fractional units have their respective names.

This is a critical bug.

Historically, there were currencies with several fractional units, like the old British Pound sterling had 12 shillings, each shilling split into 20 pence before 1971. Thank God we should not support this.

@pavloslav
Copy link
Contributor Author

Note: there are non-decimal currencies.
1 MRU (Mauritanian ouguiya) is 5 khoums. Should 0.4 MRU be 2 khoums or 4 khoums?

@Ballasi Ballasi added this to the v1.2.0 milestone Mar 17, 2024
@Ballasi Ballasi self-assigned this Mar 17, 2024
@Ballasi
Copy link
Owner

Ballasi commented Mar 17, 2024

I have added functionality for different currency cent names. However, after looking at the currencies that does not implement /100 subunits, it seems like it is very unlikely we are going to implement them in the future.

The only ones that are already included and does not use a /100 subunit is for instance yuan, which can be split in either /10 (jiao) or /100 (fen), and they are almost never used.

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

No branches or pull requests

2 participants