Closed xmha97 closed 10 months ago
This is controlled by holidays
library and I think is related to the version used and how it extracts locale from the system. I noticed the change of the language as well. I think it's better to ask this at that library. Here, I have no control over it.
Specifically, Iran is supported in two languages, so holidays
python lib chooses the language depending on your system, not sure how. Check their documentation via that link to possibly fix that. I think you'll need to add fa
locale to display it in Persian, but I can't be sure.
Interesting, on my Arch system I see the holidays names are shown in Persian. I also get them in Python:
$ python -c 'from holidays import countries; print(list(countries.Iran(2023).values())[:3])'
['نوروز', 'نوروز', 'نوروز']
python-holidays
= 0.34.
Update:
Things are different if I set LANG
to en_US
so you may want to check that too:
$ LANG=en_US python -c 'from holidays import countries; print(list(countries.Iran(2023).values())[:3])'
['Persian New Year', 'Persian New Year', 'Persian New Year']
I think there's a default language for each country in holidays
library and some additionally supported languages. So, if your LANG is anything but en_US then by default it's in Arabic, but if it's specifically en_US then holidays
displays events in the additionally supported English language.
Again, this is not something I can override, so I'll close this issue.
I set
holiday_country = Iran
on Ubuntu and Windows. On Ubuntu, I see holiday events in English. But on Windows, I see holiday events in Persian. Why?