holidays 0.83__py3-none-any.whl → 0.84__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (64) hide show
  1. holidays/calendars/balinese_saka.py +2 -3
  2. holidays/calendars/buddhist.py +3 -4
  3. holidays/calendars/burmese.py +9 -10
  4. holidays/calendars/chinese.py +8 -9
  5. holidays/calendars/hebrew.py +10 -11
  6. holidays/calendars/hindu.py +27 -28
  7. holidays/calendars/mandaean.py +2 -3
  8. holidays/calendars/mongolian.py +4 -5
  9. holidays/calendars/persian.py +2 -3
  10. holidays/calendars/sinhala.py +25 -14
  11. holidays/calendars/thai.py +13 -14
  12. holidays/calendars/tibetan.py +12 -13
  13. holidays/countries/angola.py +1 -2
  14. holidays/countries/austria.py +1 -1
  15. holidays/countries/guernsey.py +1 -2
  16. holidays/countries/italy.py +2 -2
  17. holidays/countries/jersey.py +1 -2
  18. holidays/countries/malta.py +1 -1
  19. holidays/countries/portugal.py +6 -3
  20. holidays/countries/sint_maarten.py +1 -1
  21. holidays/countries/spain.py +418 -214
  22. holidays/countries/sri_lanka.py +37 -33
  23. holidays/countries/taiwan.py +2 -2
  24. holidays/countries/united_kingdom.py +1 -2
  25. holidays/countries/united_states.py +1 -2
  26. holidays/groups/balinese_saka.py +2 -3
  27. holidays/groups/buddhist.py +4 -5
  28. holidays/groups/burmese.py +11 -12
  29. holidays/groups/chinese.py +18 -19
  30. holidays/groups/christian.py +20 -0
  31. holidays/groups/eastern.py +2 -3
  32. holidays/groups/hebrew.py +7 -10
  33. holidays/groups/hindu.py +36 -37
  34. holidays/groups/mandaean.py +13 -14
  35. holidays/groups/mongolian.py +7 -8
  36. holidays/groups/persian.py +14 -15
  37. holidays/groups/sinhala.py +13 -14
  38. holidays/groups/thai.py +12 -13
  39. holidays/groups/tibetan.py +16 -17
  40. holidays/holiday_base.py +34 -33
  41. holidays/ical.py +1 -2
  42. holidays/locale/ca/LC_MESSAGES/ES.mo +0 -0
  43. holidays/locale/en_US/LC_MESSAGES/ES.mo +0 -0
  44. holidays/locale/en_US/LC_MESSAGES/LK.mo +0 -0
  45. holidays/locale/es/LC_MESSAGES/ES.mo +0 -0
  46. holidays/locale/si_LK/LC_MESSAGES/LK.mo +0 -0
  47. holidays/locale/ta_LK/LC_MESSAGES/LK.mo +0 -0
  48. holidays/locale/th/LC_MESSAGES/CN.mo +0 -0
  49. holidays/locale/th/LC_MESSAGES/ES.mo +0 -0
  50. holidays/locale/th/LC_MESSAGES/HK.mo +0 -0
  51. holidays/locale/th/LC_MESSAGES/KR.mo +0 -0
  52. holidays/locale/th/LC_MESSAGES/MO.mo +0 -0
  53. holidays/locale/uk/LC_MESSAGES/ES.mo +0 -0
  54. holidays/mixins/child_entity.py +1 -3
  55. holidays/observed_holiday_base.py +12 -13
  56. holidays/registry.py +3 -3
  57. holidays/utils.py +13 -14
  58. holidays/version.py +1 -1
  59. {holidays-0.83.dist-info → holidays-0.84.dist-info}/METADATA +3 -4
  60. {holidays-0.83.dist-info → holidays-0.84.dist-info}/RECORD +64 -63
  61. {holidays-0.83.dist-info → holidays-0.84.dist-info}/WHEEL +0 -0
  62. {holidays-0.83.dist-info → holidays-0.84.dist-info}/licenses/CONTRIBUTORS +0 -0
  63. {holidays-0.83.dist-info → holidays-0.84.dist-info}/licenses/LICENSE +0 -0
  64. {holidays-0.83.dist-info → holidays-0.84.dist-info}/top_level.txt +0 -0
@@ -54,9 +54,10 @@ class SriLanka(
54
54
  References:
55
55
  * [No. 29 of 1971 (Holidays Act)](https://web.archive.org/web/20250315041521/http://www.commonlii.org/lk/legis/num_act/ha29o1971152/)
56
56
  * [No. 21 of 1991 (Amendment)](https://web.archive.org/web/20200221094206/http://www.commonlii.org:80/lk/legis/num_act/ha21o1991232/)
57
- * <https://web.archive.org/web/20110722150724/http://www.pubad.gov.lk/Holidays/holidays%202003.htm>
58
- * <https://web.archive.org/web/20111018053717/http://www.pubad.gov.lk/Holidays/Public%20&%20Bank%20Holidays%202004.pdf>
59
- * <https://web.archive.org/web/20241120204015/https://documents.gov.lk/en/calendar.php>
57
+ * [2003](https://web.archive.org/web/20110722150724/http://www.pubad.gov.lk/Holidays/holidays%202003.htm)
58
+ * [2004](https://web.archive.org/web/20111018053717/http://www.pubad.gov.lk/Holidays/Public%20&%20Bank%20Holidays%202004.pdf)
59
+ * [2005-2025](https://web.archive.org/web/20241120204015/https://documents.gov.lk/en/calendar.php)
60
+ * [2026](https://archive.org/details/2438-22-e)
60
61
 
61
62
  Cross-Checked With:
62
63
  * <https://web.archive.org/web/20111018053927/http://www.pubad.gov.lk/Holidays/Public%20&%20Bank%20Holidays%202005.pdf>
@@ -82,11 +83,11 @@ class SriLanka(
82
83
  # %s (estimated).
83
84
  estimated_label = tr("%s (අනුමානිත)")
84
85
  supported_languages = ("en_US", "si_LK", "ta_LK")
85
- # Sri Lanka's Holidays Act (No. 29 of 1971) was first proclaimed on SEP 2nd, 1971
86
- # but the earliest citable calendar online is from 2003.
87
- # As there's no source for future Poya dates, end year is capped at 2025.
88
- start_year = 1972
89
- end_year = 2025
86
+ # Sri Lanka's Holidays Act (No. 29 of 1971) was first proclaimed on September 2nd, 1971
87
+ # but the earliest citable online calendar reference is from 2003. As Poya dates are
88
+ # approved on a yearly basis by the Poya committee, the end year is capped at 2026.
89
+ start_year = 2003
90
+ end_year = 2026
90
91
 
91
92
  def __init__(self, *args, islamic_show_estimated: bool = True, **kwargs):
92
93
  """
@@ -117,6 +118,7 @@ class SriLanka(
117
118
  # Tamil Thai Pongal Day.
118
119
  name = tr("දෙමළ තෛපොංැලල් දිනය")
119
120
  thai_pongal_years_jan_14 = {
121
+ # Sri Lanka's isn't an exact match with India's, i.e. 2026, used with caution.
120
122
  2005,
121
123
  2006,
122
124
  2009,
@@ -154,13 +156,19 @@ class SriLanka(
154
156
  # Day Before Sinhala and Tamil New Year.
155
157
  self._add_holiday(tr("සිංහල හා දෙමළ අලුත් අවුරුදු දිනට පෙර දිනය"), _timedelta(dt, -1))
156
158
 
159
+ # Good Friday.
160
+ self._add_good_friday(tr("මහ සිකුරාදා දිනය"))
161
+
157
162
  # International Workers' Day.
158
163
  self._add_labor_day(tr("ලොක කම්කරු දිනය"))
159
164
 
165
+ # Christmas Day.
166
+ self._add_christmas_day(tr("නත්තල් උත්සව දිනය"))
167
+
160
168
  # Hindu Holidays.
161
169
 
162
170
  maha_sivarathri_dates = {
163
- # The one used in Sri Lanka isn't an exact match with India, used with caution.
171
+ # Sri Lanka's isn't an exact match with India's, i.e. 2010, used with caution.
164
172
  2003: (MAR, 1),
165
173
  2004: (FEB, 18),
166
174
  2005: (MAR, 8),
@@ -184,25 +192,16 @@ class SriLanka(
184
192
  2023: (FEB, 18),
185
193
  2024: (MAR, 8),
186
194
  2025: (FEB, 26),
195
+ 2026: (FEB, 15),
187
196
  }
188
- maha_sivarathri_date = maha_sivarathri_dates.get(self._year)
189
- if maha_sivarathri_date:
190
- # Maha Sivarathri Day.
191
- self._add_holiday(tr("මහ සිවරාත්රි දිනය"), maha_sivarathri_date)
197
+ # Maha Sivarathri Day.
198
+ self._add_holiday(tr("මහ සිවරාත්රි දිනය"), maha_sivarathri_dates.get(self._year))
192
199
 
193
200
  # Deepavali was a working day in 2003.
194
201
  if self._year >= 2004:
195
202
  # Deepavali Festival Day.
196
203
  self._add_diwali(tr("දීපවාලි උත්සව දිනය"))
197
204
 
198
- # Christian Holidays.
199
-
200
- # Good Friday.
201
- self._add_good_friday(tr("මහ සිකුරාදා දිනය"))
202
-
203
- # Christmas Day.
204
- self._add_christmas_day(tr("නත්තල් උත්සව දිනය"))
205
-
206
205
  # Poya Holidays.
207
206
  # All Adhi Poya Holidays will instead be added in StaticHolidays.
208
207
 
@@ -219,11 +218,10 @@ class SriLanka(
219
218
  self._add_bak_poya(tr("බක් පුර පසළොස්වක පෝය දිනය"))
220
219
 
221
220
  # Vesak Full Moon Poya Day.
222
- dt = self._add_vesak_poya(tr("වෙසක් පුර පසළොස්වක පෝය දිනය"))
221
+ vesak_poya = self._add_vesak_poya(tr("වෙසක් පුර පසළොස්වක පෝය දිනය"))
223
222
 
224
- if self._year >= 2003:
225
- # Day Following Vesak Full Moon Poya Day.
226
- self._add_holiday(tr("වෙසක් පුර පසළොස්වක පෝය දිනට පසු දිනය"), _timedelta(dt, +1))
223
+ # Day Following Vesak Full Moon Poya Day.
224
+ self._add_holiday(tr("වෙසක් පුර පසළොස්වක පෝය දිනට පසු දිනය"), _timedelta(vesak_poya, +1))
227
225
 
228
226
  # Poson Full Moon Poya Day.
229
227
  self._add_poson_poya(tr("පොසොන් පුර පසළොස්වක පෝය දිනය"))
@@ -291,21 +289,23 @@ class SriLankaHinduHolidays(_CustomHinduHolidays):
291
289
  2023: (NOV, 12),
292
290
  2024: (OCT, 31),
293
291
  2025: (OCT, 20),
292
+ 2026: (NOV, 8),
294
293
  }
295
294
 
296
295
 
297
296
  class SriLankaIslamicHolidays(_CustomIslamicHolidays):
298
297
  # https://web.archive.org/web/20111103102902/http://www.adaderana.lk:80/news.php?nid=15606
299
298
  # https://web.archive.org/web/20121029024049/http://www.adaderana.lk:80/news.php?nid=20136
300
- EID_AL_ADHA_DATES_CONFIRMED_YEARS = (2003, 2025)
299
+ EID_AL_ADHA_DATES_CONFIRMED_YEARS = (2003, 2026)
301
300
  EID_AL_ADHA_DATES = {
302
301
  2004: (FEB, 1),
303
302
  2005: (JAN, 21),
304
303
  2006: ((JAN, 11), (DEC, 31)),
305
304
  2017: (SEP, 1),
305
+ 2026: (MAY, 28),
306
306
  }
307
307
 
308
- EID_AL_FITR_DATES_CONFIRMED_YEARS = (2003, 2025)
308
+ EID_AL_FITR_DATES_CONFIRMED_YEARS = (2003, 2026)
309
309
  EID_AL_FITR_DATES = {
310
310
  2004: (NOV, 14),
311
311
  2007: (OCT, 13),
@@ -314,13 +314,15 @@ class SriLankaIslamicHolidays(_CustomIslamicHolidays):
314
314
  2012: (AUG, 19),
315
315
  2016: (JUL, 6),
316
316
  2018: (JUN, 15),
317
+ 2026: (MAR, 21),
317
318
  }
318
319
 
319
- MAWLID_DATES_CONFIRMED_YEARS = (2003, 2025)
320
+ MAWLID_DATES_CONFIRMED_YEARS = (2003, 2026)
320
321
  MAWLID_DATES = {
321
322
  2008: (MAR, 20),
322
323
  2015: (JAN, 4),
323
324
  2018: (NOV, 20),
325
+ 2026: (AUG, 26),
324
326
  }
325
327
 
326
328
 
@@ -407,7 +409,7 @@ class SriLankaStaticHolidays:
407
409
  ),
408
410
  2019: (
409
411
  (APR, 15, special_bank_holiday_name),
410
- # MAY 20 got upgraded to Special Public Holiday.
412
+ # May 20th, 2019 got upgraded to Special Public Holiday.
411
413
  (NOV, 11, special_bank_holiday_name),
412
414
  ),
413
415
  2020: (APR, 14, special_bank_holiday_name),
@@ -416,7 +418,7 @@ class SriLankaStaticHolidays:
416
418
  (DEC, 24, half_day_special_bank_holiday_name),
417
419
  ),
418
420
  2022: (
419
- # MAY 2 got upgraded to Special Public Holiday.
421
+ # May 2nd got upgraded to Special Public Holiday.
420
422
  (OCT, 10, special_bank_holiday_name),
421
423
  (DEC, 26, special_bank_holiday_name),
422
424
  ),
@@ -428,7 +430,7 @@ class SriLankaStaticHolidays:
428
430
  2020: (JUN, 4, public_sector_holiday_name),
429
431
  2022: (
430
432
  (JUN, 13, public_sector_holiday_name),
431
- # All Friday between JUN 15, 2022 to AUG 2, 2022.
433
+ # All Friday between June 15th, 2022 to August 2nd, 2022.
432
434
  (JUN, 17, public_sector_holiday_name),
433
435
  (JUN, 24, public_sector_holiday_name),
434
436
  (JUL, 1, public_sector_holiday_name),
@@ -443,7 +445,7 @@ class SriLankaStaticHolidays:
443
445
  2004: (JUL, 31, adhi_esala_poya_name),
444
446
  2007: (MAY, 31, adhi_poson_poya_name),
445
447
  2010: (APR, 28, adhi_vesak_poya_name),
446
- # 2011, MAY 2 confirmed as not getting upgrade to Special Public Holiday.
448
+ # May 2nd, 2011 confirmed as not getting upgrade to Special Public Holiday.
447
449
  2012: (
448
450
  (MAY, 7, special_public_holiday_name),
449
451
  (AUG, 31, adhi_binara_poya_name),
@@ -470,8 +472,10 @@ class SriLankaStaticHolidays:
470
472
  (APR, 15, special_public_holiday_name),
471
473
  (SEP, 29, special_public_holiday_name),
472
474
  ),
475
+ 2026: (MAY, 30, adhi_poson_poya_name),
473
476
  }
474
477
 
475
478
  special_workday_holidays = {
476
- 2003: (OCT, 24, tr("දීපවාලි උත්සව දිනය")), # Deepavali Festival Day.
479
+ # Deepavali Festival Day.
480
+ 2003: (OCT, 24, tr("දීපවාලි උත්සව දිනය")),
477
481
  }
@@ -13,7 +13,7 @@
13
13
  from __future__ import annotations
14
14
 
15
15
  from gettext import gettext as tr
16
- from typing import Optional, TYPE_CHECKING
16
+ from typing import TYPE_CHECKING
17
17
 
18
18
  from holidays.calendars.gregorian import (
19
19
  JAN,
@@ -112,7 +112,7 @@ class Taiwan(ObservedHolidayBase, ChineseCalendarHolidays, InternationalHolidays
112
112
  return weekend
113
113
 
114
114
  def _populate_observed(
115
- self, dts: set[date], rule: Optional[ObservedRule] = None, since: int = 2015
115
+ self, dts: set[date], rule: ObservedRule | None = None, since: int = 2015
116
116
  ) -> None:
117
117
  """
118
118
  Taiwan's General Observance Rule first started in 2015 as per
@@ -11,7 +11,6 @@
11
11
  # License: MIT (see LICENSE file)
12
12
 
13
13
  from gettext import gettext as tr
14
- from typing import Union
15
14
 
16
15
  from holidays.calendars.gregorian import APR, MAY, JUN, JUL, SEP, DEC
17
16
  from holidays.groups import ChristianHolidays, InternationalHolidays, StaticHolidays
@@ -42,7 +41,7 @@ class UnitedKingdom(ObservedHolidayBase, ChristianHolidays, InternationalHoliday
42
41
  default_language = "en_GB"
43
42
  # %s (observed).
44
43
  observed_label = tr("%s (observed)")
45
- subdivisions: Union[tuple[()], tuple[str, ...]] = (
44
+ subdivisions: tuple[()] | tuple[str, ...] = (
46
45
  "ENG", # England
47
46
  "NIR", # Northern Ireland
48
47
  "SCT", # Scotland
@@ -11,7 +11,6 @@
11
11
  # License: MIT (see LICENSE file)
12
12
 
13
13
  from gettext import gettext as tr
14
- from typing import Union
15
14
 
16
15
  from holidays.calendars.gregorian import (
17
16
  FEB,
@@ -115,7 +114,7 @@ class UnitedStates(ObservedHolidayBase, ChristianHolidays, InternationalHolidays
115
114
  supported_languages = ("en_US", "th")
116
115
  # Independence Declared on July 4th, 1776.
117
116
  start_year = 1777
118
- subdivisions: Union[tuple[()], tuple[str, ...]] = (
117
+ subdivisions: tuple[()] | tuple[str, ...] = (
119
118
  "AK", # Alaska.
120
119
  "AL", # Alabama.
121
120
  "AR", # Arkansas.
@@ -11,7 +11,6 @@
11
11
  # License: MIT (see LICENSE file)
12
12
 
13
13
  from datetime import date
14
- from typing import Optional
15
14
 
16
15
  from holidays.calendars.balinese_saka import _BalineseSakaLunar
17
16
 
@@ -24,7 +23,7 @@ class BalineseSakaCalendarHolidays:
24
23
  def __init__(self) -> None:
25
24
  self._balinese_saka_calendar = _BalineseSakaLunar()
26
25
 
27
- def _add_balinese_saka_calendar_holiday(self, name: str, dt: Optional[date]) -> Optional[date]:
26
+ def _add_balinese_saka_calendar_holiday(self, name: str, dt: date | None) -> date | None:
28
27
  """
29
28
  Add Balinese Saka calendar holiday.
30
29
  """
@@ -32,7 +31,7 @@ class BalineseSakaCalendarHolidays:
32
31
  return None
33
32
  return self._add_holiday(name, dt)
34
33
 
35
- def _add_nyepi(self, name) -> Optional[date]:
34
+ def _add_nyepi(self, name) -> date | None:
36
35
  """
37
36
  Add Nyepi (Day following the 9th of Dark Moon (Tilem)).
38
37
 
@@ -11,7 +11,6 @@
11
11
  # License: MIT (see LICENSE file)
12
12
 
13
13
  from datetime import date
14
- from typing import Optional
15
14
 
16
15
  from holidays.calendars.buddhist import _BuddhistLunisolar
17
16
  from holidays.groups.eastern import EasternCalendarHolidays
@@ -27,8 +26,8 @@ class BuddhistCalendarHolidays(EasternCalendarHolidays):
27
26
  self._buddhist_calendar_show_estimated = show_estimated
28
27
 
29
28
  def _add_buddhist_calendar_holiday(
30
- self, name: str, dt_estimated: tuple[Optional[date], bool]
31
- ) -> Optional[date]:
29
+ self, name: str, dt_estimated: tuple[date | None, bool]
30
+ ) -> date | None:
32
31
  """
33
32
  Add Buddhist calendar holiday.
34
33
 
@@ -39,7 +38,7 @@ class BuddhistCalendarHolidays(EasternCalendarHolidays):
39
38
  name, dt_estimated, show_estimated=self._buddhist_calendar_show_estimated
40
39
  )
41
40
 
42
- def _add_vesak(self, name) -> Optional[date]:
41
+ def _add_vesak(self, name) -> date | None:
43
42
  """
44
43
  Add Vesak (15th day of the 4th lunar month).
45
44
 
@@ -50,7 +49,7 @@ class BuddhistCalendarHolidays(EasternCalendarHolidays):
50
49
  name, self._buddhist_calendar.vesak_date(self._year)
51
50
  )
52
51
 
53
- def _add_vesak_may(self, name) -> Optional[date]:
52
+ def _add_vesak_may(self, name) -> date | None:
54
53
  """
55
54
  Add Vesak (on the day of the first full moon in May
56
55
  in the Gregorian calendar).
@@ -11,7 +11,6 @@
11
11
  # License: MIT (see LICENSE file)
12
12
 
13
13
  from datetime import date
14
- from typing import Optional
15
14
 
16
15
  from holidays.calendars.burmese import _BurmeseLunisolar
17
16
  from holidays.calendars.gregorian import _timedelta
@@ -24,8 +23,8 @@ class BurmeseCalendarHolidays:
24
23
  self._burmese_calendar = _BurmeseLunisolar()
25
24
 
26
25
  def _add_burmese_calendar_holiday(
27
- self, name: str, dt: Optional[date] = None, days_delta: int = 0
28
- ) -> Optional[date]:
26
+ self, name: str, dt: date | None = None, days_delta: int = 0
27
+ ) -> date | None:
29
28
  """Add Burmese calendar holiday."""
30
29
 
31
30
  if dt is None:
@@ -61,7 +60,7 @@ class BurmeseCalendarHolidays:
61
60
  )
62
61
  }
63
62
 
64
- def _add_kason_full_moon_day(self, name: str) -> Optional[date]:
63
+ def _add_kason_full_moon_day(self, name: str) -> date | None:
65
64
  """Add Full Moon Day of Kason holiday.
66
65
 
67
66
  Vesak is known as the Full Moon Day of Kason, which is the second month
@@ -79,7 +78,7 @@ class BurmeseCalendarHolidays:
79
78
  name, self._burmese_calendar.kason_full_moon_date(self._year)
80
79
  )
81
80
 
82
- def _add_myanmar_diwali(self, name: str) -> Optional[date]:
81
+ def _add_myanmar_diwali(self, name: str) -> date | None:
83
82
  """Add Myanmar Diwali holiday.
84
83
 
85
84
  Diwali (Deepavali, Festival of Lights) is one of the most important festivals
@@ -98,7 +97,7 @@ class BurmeseCalendarHolidays:
98
97
  name, self._burmese_calendar.tazaungmon_waxing_moon_date(self._year)
99
98
  )
100
99
 
101
- def _add_myanmar_national_day(self, name: str) -> Optional[date]:
100
+ def _add_myanmar_national_day(self, name: str) -> date | None:
102
101
  """Add Myanmar National Day holiday.
103
102
 
104
103
  National Day is a public holiday in Myanmar, marking the anniversary of the first
@@ -163,7 +162,7 @@ class BurmeseCalendarHolidays:
163
162
  if (dt := self._add_holiday(name, _timedelta(akya, delta)))
164
163
  }
165
164
 
166
- def _add_tabaung_full_moon_day(self, name: str) -> Optional[date]:
165
+ def _add_tabaung_full_moon_day(self, name: str) -> date | None:
167
166
  """Add Full Moon Day of Tabaung holiday.
168
167
 
169
168
  Māgha Pūjā (also written as Makha Bucha Day, Meak Bochea) is a Buddhist festival
@@ -181,7 +180,7 @@ class BurmeseCalendarHolidays:
181
180
  name, self._burmese_calendar.tabaung_full_moon_date(self._year - 1)
182
181
  )
183
182
 
184
- def _add_tazaungmon_full_moon_day(self, name: str) -> Optional[date]:
183
+ def _add_tazaungmon_full_moon_day(self, name: str) -> date | None:
185
184
  """Add Full Moon Day of Tazaungmon holiday.
186
185
 
187
186
  The Tazaungdaing Festival, also known as the Festival of Lights, held on the full moon day
@@ -199,7 +198,7 @@ class BurmeseCalendarHolidays:
199
198
  name, self._burmese_calendar.tazaungmon_full_moon_date(self._year)
200
199
  )
201
200
 
202
- def _add_thadingyut_full_moon_eve(self, name: str) -> Optional[date]:
201
+ def _add_thadingyut_full_moon_eve(self, name: str) -> date | None:
203
202
  """Add Pre-Full Moon Day of Thadingyut holiday.
204
203
 
205
204
  The Thadingyut Festival, also known as the Lighting Festival of Myanmar, is held
@@ -217,7 +216,7 @@ class BurmeseCalendarHolidays:
217
216
  name, self._burmese_calendar.thadingyut_full_moon_date(self._year), days_delta=-1
218
217
  )
219
218
 
220
- def _add_thadingyut_full_moon_day(self, name: str) -> Optional[date]:
219
+ def _add_thadingyut_full_moon_day(self, name: str) -> date | None:
221
220
  """Add Full Moon Day of Thadingyut holiday.
222
221
 
223
222
  The Thadingyut Festival, also known as the Lighting Festival of Myanmar, is held
@@ -235,7 +234,7 @@ class BurmeseCalendarHolidays:
235
234
  name, self._burmese_calendar.thadingyut_full_moon_date(self._year)
236
235
  )
237
236
 
238
- def _add_thadingyut_full_moon_day_two(self, name: str) -> Optional[date]:
237
+ def _add_thadingyut_full_moon_day_two(self, name: str) -> date | None:
239
238
  """Add Post-Full Moon Day of Thadingyut holiday.
240
239
 
241
240
  The Thadingyut Festival, also known as the Lighting Festival of Myanmar, is held
@@ -253,7 +252,7 @@ class BurmeseCalendarHolidays:
253
252
  name, self._burmese_calendar.thadingyut_full_moon_date(self._year), days_delta=+1
254
253
  )
255
254
 
256
- def _add_waso_full_moon_day(self, name: str) -> Optional[date]:
255
+ def _add_waso_full_moon_day(self, name: str) -> date | None:
257
256
  """Add Full Moon Day of Waso holiday.
258
257
 
259
258
  Vassa is the three-month annual retreat observed by Theravada Buddhists.
@@ -11,7 +11,6 @@
11
11
  # License: MIT (see LICENSE file)
12
12
 
13
13
  from datetime import date
14
- from typing import Optional
15
14
 
16
15
  from holidays.calendars.chinese import _ChineseLunisolar, CHINESE_CALENDAR
17
16
  from holidays.calendars.gregorian import APR
@@ -83,8 +82,8 @@ class ChineseCalendarHolidays(EasternCalendarHolidays):
83
82
  return self._chinese_calendar.winter_solstice_date(self._year)[0]
84
83
 
85
84
  def _add_chinese_calendar_holiday(
86
- self, name: str, dt_estimated: tuple[Optional[date], bool], days_delta: int = 0
87
- ) -> Optional[date]:
85
+ self, name: str, dt_estimated: tuple[date | None, bool], days_delta: int = 0
86
+ ) -> date | None:
88
87
  """
89
88
  Add Chinese calendar holiday.
90
89
 
@@ -98,7 +97,7 @@ class ChineseCalendarHolidays(EasternCalendarHolidays):
98
97
  days_delta=days_delta,
99
98
  )
100
99
 
101
- def _add_chinese_birthday_of_buddha(self, name) -> Optional[date]:
100
+ def _add_chinese_birthday_of_buddha(self, name) -> date | None:
102
101
  """
103
102
  Add Birthday of the Buddha by Chinese lunar calendar (8th day of the
104
103
  4th lunar month).
@@ -112,7 +111,7 @@ class ChineseCalendarHolidays(EasternCalendarHolidays):
112
111
  name, self._chinese_calendar.buddha_birthday_date(self._year)
113
112
  )
114
113
 
115
- def _add_chinese_day_before_new_years_eve(self, name) -> Optional[date]:
114
+ def _add_chinese_day_before_new_years_eve(self, name) -> date | None:
116
115
  """
117
116
  Add day before Chinese New Year's Eve (second to last day of 12th lunar month).
118
117
 
@@ -123,7 +122,7 @@ class ChineseCalendarHolidays(EasternCalendarHolidays):
123
122
  name, self._chinese_calendar.lunar_new_year_date(self._year), days_delta=-2
124
123
  )
125
124
 
126
- def _add_chinese_new_years_eve(self, name) -> Optional[date]:
125
+ def _add_chinese_new_years_eve(self, name) -> date | None:
127
126
  """
128
127
  Add Chinese New Year's Eve (last day of 12th lunar month).
129
128
 
@@ -134,7 +133,7 @@ class ChineseCalendarHolidays(EasternCalendarHolidays):
134
133
  name, self._chinese_calendar.lunar_new_year_date(self._year), days_delta=-1
135
134
  )
136
135
 
137
- def _add_chinese_new_years_day(self, name) -> Optional[date]:
136
+ def _add_chinese_new_years_day(self, name) -> date | None:
138
137
  """
139
138
  Add Chinese New Year's Day (first day of the first lunar month).
140
139
 
@@ -146,7 +145,7 @@ class ChineseCalendarHolidays(EasternCalendarHolidays):
146
145
  name, self._chinese_calendar.lunar_new_year_date(self._year)
147
146
  )
148
147
 
149
- def _add_chinese_new_years_day_two(self, name) -> Optional[date]:
148
+ def _add_chinese_new_years_day_two(self, name) -> date | None:
150
149
  """
151
150
  Add Chinese New Year's Day Two.
152
151
 
@@ -156,7 +155,7 @@ class ChineseCalendarHolidays(EasternCalendarHolidays):
156
155
  name, self._chinese_calendar.lunar_new_year_date(self._year), days_delta=+1
157
156
  )
158
157
 
159
- def _add_chinese_new_years_day_three(self, name) -> Optional[date]:
158
+ def _add_chinese_new_years_day_three(self, name) -> date | None:
160
159
  """
161
160
  Add Chinese New Year's Day Three.
162
161
 
@@ -166,7 +165,7 @@ class ChineseCalendarHolidays(EasternCalendarHolidays):
166
165
  name, self._chinese_calendar.lunar_new_year_date(self._year), days_delta=+2
167
166
  )
168
167
 
169
- def _add_chinese_new_years_day_four(self, name) -> Optional[date]:
168
+ def _add_chinese_new_years_day_four(self, name) -> date | None:
170
169
  """
171
170
  Add Chinese New Year's Day Four.
172
171
 
@@ -176,7 +175,7 @@ class ChineseCalendarHolidays(EasternCalendarHolidays):
176
175
  name, self._chinese_calendar.lunar_new_year_date(self._year), days_delta=+3
177
176
  )
178
177
 
179
- def _add_chinese_new_years_day_five(self, name) -> Optional[date]:
178
+ def _add_chinese_new_years_day_five(self, name) -> date | None:
180
179
  """
181
180
  Add Chinese New Year's Day Five.
182
181
 
@@ -186,7 +185,7 @@ class ChineseCalendarHolidays(EasternCalendarHolidays):
186
185
  name, self._chinese_calendar.lunar_new_year_date(self._year), days_delta=+4
187
186
  )
188
187
 
189
- def _add_daeboreum_day(self, name) -> Optional[date]:
188
+ def _add_daeboreum_day(self, name) -> date | None:
190
189
  """
191
190
  Add Daeboreum Day (15th day of 1st lunar month).
192
191
 
@@ -198,7 +197,7 @@ class ChineseCalendarHolidays(EasternCalendarHolidays):
198
197
  name, self._chinese_calendar.lunar_new_year_date(self._year), days_delta=+14
199
198
  )
200
199
 
201
- def _add_dongzhi_festival(self, name) -> Optional[date]:
200
+ def _add_dongzhi_festival(self, name) -> date | None:
202
201
  """
203
202
  Add Dongzhi Festival (Chinese Winter Solstice).
204
203
 
@@ -209,7 +208,7 @@ class ChineseCalendarHolidays(EasternCalendarHolidays):
209
208
  """
210
209
  return self._add_holiday(name, self._dongzhi_festival)
211
210
 
212
- def _add_hanshi_festival(self, name) -> Optional[date]:
211
+ def _add_hanshi_festival(self, name) -> date | None:
213
212
  """
214
213
  Add Hanshi Festival (105 days after Winter Solstice).
215
214
 
@@ -232,7 +231,7 @@ class ChineseCalendarHolidays(EasternCalendarHolidays):
232
231
  """
233
232
  return self._add_holiday(name, self._qingming_festival)
234
233
 
235
- def _add_double_ninth_festival(self, name) -> Optional[date]:
234
+ def _add_double_ninth_festival(self, name) -> date | None:
236
235
  """
237
236
  Add Double Ninth Festival (9th day of 9th lunar month).
238
237
 
@@ -244,7 +243,7 @@ class ChineseCalendarHolidays(EasternCalendarHolidays):
244
243
  name, self._chinese_calendar.double_ninth_date(self._year)
245
244
  )
246
245
 
247
- def _add_dragon_boat_festival(self, name) -> Optional[date]:
246
+ def _add_dragon_boat_festival(self, name) -> date | None:
248
247
  """
249
248
  Add Dragon Boat Festival (5th day of 5th lunar month).
250
249
 
@@ -256,7 +255,7 @@ class ChineseCalendarHolidays(EasternCalendarHolidays):
256
255
  name, self._chinese_calendar.dragon_boat_date(self._year)
257
256
  )
258
257
 
259
- def _add_hung_kings_day(self, name) -> Optional[date]:
258
+ def _add_hung_kings_day(self, name) -> date | None:
260
259
  """
261
260
  Add Hùng Kings' Temple Festival (10th day of the 3rd lunar month).
262
261
 
@@ -268,7 +267,7 @@ class ChineseCalendarHolidays(EasternCalendarHolidays):
268
267
  name, self._chinese_calendar.hung_kings_date(self._year)
269
268
  )
270
269
 
271
- def _add_mid_autumn_festival(self, name) -> Optional[date]:
270
+ def _add_mid_autumn_festival(self, name) -> date | None:
272
271
  """
273
272
  Add Mid Autumn Festival (15th day of the 8th lunar month).
274
273
 
@@ -280,7 +279,7 @@ class ChineseCalendarHolidays(EasternCalendarHolidays):
280
279
  name, self._chinese_calendar.mid_autumn_date(self._year)
281
280
  )
282
281
 
283
- def _add_mid_autumn_festival_day_two(self, name) -> Optional[date]:
282
+ def _add_mid_autumn_festival_day_two(self, name) -> date | None:
284
283
  """
285
284
  Add Mid Autumn Festival Day Two (16th day of the 8th lunar month).
286
285
 
@@ -414,6 +414,16 @@ class ChristianHolidays:
414
414
  """
415
415
  return self._add_holiday(name, _timedelta(self._easter_sunday, +9))
416
416
 
417
+ def _add_saint_anthonys_day(self, name) -> date:
418
+ """
419
+ Add Saint Anthony of Padua's Day (June 13th).
420
+
421
+ Saint Anthony's Day is celebrated on 13 June, the traditionally
422
+ accepted date of the saint's death.
423
+ https://en.wikipedia.org/wiki/Anthony_of_Padua
424
+ """
425
+ return self._add_holiday_jun_13(name)
426
+
417
427
  def _add_saint_georges_day(self, name) -> date:
418
428
  """
419
429
  Add Saint George's Day (April 23th).
@@ -455,6 +465,16 @@ class ChristianHolidays:
455
465
  """
456
466
  return self._add_holiday_mar_19(name)
457
467
 
468
+ def _add_saint_martins_day(self, name) -> date:
469
+ """
470
+ Add Saint Martin of Tours Day (November 11th).
471
+
472
+ Saint Martin of Tours is the patron saint of many communities and organizations
473
+ across Europe, including France's Third Republic.
474
+ https://en.wikipedia.org/wiki/Martin_of_Tours
475
+ """
476
+ return self._add_holiday_nov_11(name)
477
+
458
478
  def _add_saint_patricks_day(self, name) -> date:
459
479
  """
460
480
  Add Saint Patrick's Day (March 17th).
@@ -12,7 +12,6 @@
12
12
 
13
13
  from collections.abc import Iterable
14
14
  from datetime import date
15
- from typing import Optional
16
15
 
17
16
  from holidays.calendars.gregorian import _timedelta
18
17
 
@@ -25,11 +24,11 @@ class EasternCalendarHolidays:
25
24
  def _add_eastern_calendar_holiday(
26
25
  self,
27
26
  name: str,
28
- dt_estimated: tuple[Optional[date], bool],
27
+ dt_estimated: tuple[date | None, bool],
29
28
  *,
30
29
  show_estimated: bool = True,
31
30
  days_delta: int = 0,
32
- ) -> Optional[date]:
31
+ ) -> date | None:
33
32
  """
34
33
  Add Eastern (Buddhist, Chinese, Hindu, Islamic, Mongolian) calendar holiday.
35
34