Skip to content

Update Ethiopia holidays: official source namings, WORKDAY category#2490

Merged
arkid15r merged 2 commits intovacanza:devfrom
PPsyrius:eth_2025
Apr 23, 2025
Merged

Update Ethiopia holidays: official source namings, WORKDAY category#2490
arkid15r merged 2 commits intovacanza:devfrom
PPsyrius:eth_2025

Conversation

@PPsyrius
Copy link
Copy Markdown
Collaborator

@PPsyrius PPsyrius commented Apr 23, 2025

Proposed change

  • Adds Ethiopia's previous 2024-2025 actual Islamic holidays.
  • Adds type annotation for _is_leap_year(self) to match holidays/holiday_base.py ones as mentioned in Update _ThaiLunisolar and ThaiCalendarHolidays documentation #2439 .
  • Adds WORKDAY holiday categories from the official sources.
  • Updates en_US, am as appropriate with the official translations, adds en_ET which is accurate to the original source as well.
  • Moves the start_year to 1976 as we didn't have access to any documents prior to the Negarit Gazeta ​Proclamation No. 16/1975.
  • Refactors test cases as appropriate.

Note

I tried to update the ar l10n for Ethiopia to match the official holiday names - but since the official source doesn't include Arabic nor did I speaks it, reviews by human reviewers are welcome.

Type of change

  • New country/market holidays support (thank you!)
  • Supported country/market holidays update (calendar discrepancy fix, localization)
  • Existing code/documentation/test/process quality improvement (best practice, cleanup, refactoring, optimization)
  • Dependency update (version deprecation/pin/upgrade)
  • Bugfix (non-breaking change which fixes an issue)
  • Breaking change (a code change causing existing functionality to break)
  • New feature (new holidays functionality in general)

Checklist

@coderabbitai
Copy link
Copy Markdown
Contributor

coderabbitai bot commented Apr 23, 2025

Summary by CodeRabbit

  • New Features

    • Added support for Ethiopian Martyrs' Day (Feb 20) and Nations, Nationalities and Peoples Day (Dec 9) as recognized holidays.
    • Introduced English (Ethiopian) locale translations for Ethiopian holidays.
  • Improvements

    • Updated holiday names for Ethiopia to be more descriptive and standardized across all supported languages.
    • Expanded supported languages for Ethiopian holidays, including Amharic, Arabic, US English, and Ethiopian English.
    • Updated supported holiday categories for Ethiopia to include both public and workday holidays.
  • Bug Fixes

    • Adjusted holiday date ranges and naming for greater accuracy and consistency.
  • Documentation

    • Updated README and localization files to reflect new holidays, languages, and categories.
  • Tests

    • Enhanced and extended test coverage for new holidays, localizations, and category filtering.

Summary by CodeRabbit

  • New Features

    • Added Ethiopian Martyrs' Day (Feb 20) and Nations, Nationalities and Peoples Day (Dec 9) as recognized holidays.
    • Introduced support for the Ethiopian English locale (en_ET) with localized holiday names.
    • Expanded supported holiday categories to include both public and workday holidays for Ethiopia.
  • Improvements

    • Updated holiday names to be more descriptive and formal across all supported languages.
    • Enhanced localization for Amharic, Arabic, and English (US and Ethiopian) with clearer and more accurate translations.
    • Standardized and modernized holiday naming conventions in datasets and documentation.
  • Bug Fixes

    • Adjusted holiday date ranges and conditions to reflect accurate historical observance (e.g., Adwa Victory Day, Revolution Day).
  • Documentation

    • Updated README and supported countries table to reflect new languages and categories.
  • Tests

    • Expanded and updated tests to cover new holidays, improved localization, and refined holiday date ranges.

Walkthrough

This update revises and expands support for Ethiopian holidays across code, documentation, tests, and localization. The Ethiopia holiday class now includes more descriptive holiday names, additional legal references, and new holidays such as Ethiopian Martyrs' Day and Nations, Nationalities and Peoples Day. The supported languages list is extended to include "en_ET", with a corresponding new localization file. Holiday categories now include both PUBLIC and WORKDAY. Tests are updated for the new holiday range and categories, and all relevant translation files are synchronized with the new holiday names and additions.

Changes

Files/Paths Change Summary
README.md Updated Ethiopia's supported languages to include "en_ET" and added "WORKDAY" to supported categories in the documentation table.
holidays/countries/ethiopia.py Revised class attributes for start year, supported languages, and categories; added new holidays and legal references; updated holiday name strings; added workday holidays; extended Islamic holiday mappings; and adjusted logic for certain holidays.
holidays/locale/am/LC_MESSAGES/ET.po
holidays/locale/ar/LC_MESSAGES/ET.po
holidays/locale/en_US/LC_MESSAGES/ET.po
Expanded and clarified holiday translation strings; added new holidays; updated metadata; improved naming specificity and formality; synchronized with code changes.
holidays/locale/en_ET/LC_MESSAGES/ET.po Added new English (Ethiopia) localization file with translations for all Ethiopian holidays.
snapshots/countries/ET_COMMON.json Standardized and updated holiday names; added new holidays; removed data before 1976; adjusted dates and naming conventions for consistency.
tests/countries/test_ethiopia.py Updated test year range; added tests for new holidays and categories; revised holiday names in assertions; expanded localization tests; adjusted logic for new and renamed holidays; ensured coverage for new language and category support.

Suggested reviewers

  • PPsyrius

📜 Recent review details

Configuration used: .coderabbit.yaml
Review profile: ASSERTIVE
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between b187f98 and 8591603.

📒 Files selected for processing (2)
  • holidays/countries/ethiopia.py (6 hunks)
  • tests/countries/test_ethiopia.py (3 hunks)
🧰 Additional context used
🧠 Learnings (3)
📓 Common learnings
Learnt from: PPsyrius
PR: vacanza/holidays#2490
File: holidays/locale/en_ET/LC_MESSAGES/ET.po:99-101
Timestamp: 2025-04-23T09:53:20.034Z
Learning: For Ethiopian holidays in the en_ET locale, translations must maintain the exact official wording from government sources such as Negarit Gazeta Proclamations, even when they contain redundancies like the word "Day" appearing twice (e.g., "Ethiopian National Unity Day (Ethiopian Nations and Nationalities) Day").
holidays/countries/ethiopia.py (1)
Learnt from: PPsyrius
PR: vacanza/holidays#2490
File: holidays/countries/ethiopia.py:45-45
Timestamp: 2025-04-23T09:59:19.848Z
Learning: For the Ethiopia holidays class, it's appropriate to add a return type hint only to the `_is_leap_year` method to match the base class implementation in `holidays/holiday_base.py`, while keeping other methods without type hints to maintain consistency with other country implementations.
tests/countries/test_ethiopia.py (1)
Learnt from: PPsyrius
PR: vacanza/holidays#2416
File: tests/countries/test_turkmenistan.py:52-64
Timestamp: 2025-04-05T04:47:27.213Z
Learning: For holiday tests in the vacanza/holidays project, structure tests by individual holidays rather than by years. Each test method should focus on a specific holiday and test it across multiple years (from start_year through 2050) using helper methods like `assertHolidayName`. For fixed holidays, use generators like `(f"{year}-01-01" for year in range(1991, 2051))`. For movable holidays, specify individual dates for specific years followed by a range check.
⏰ Context from checks skipped due to timeout of 300000ms (1)
  • GitHub Check: Test Python 3.12 on windows-latest
🔇 Additional comments (16)
holidays/countries/ethiopia.py (10)

17-17: Good addition of MAR to the imports.

Including MAR from gregorian calendar is necessary to support the new 2025 Islamic holiday date on line 160.


19-19: Nice work adding the WORKDAY constant.

The WORKDAY constant is properly imported to support the new workday holiday category introduced in this update.


28-33: Great improvement to the references section.

The addition of official proclamation links and relevant external resources significantly enhances the documentation. The references to both historical (No. 29/1996) and contemporary (No. 1334/2024) proclamations provide solid grounding for the holiday definitions.


40-43: Good configuration updates for Ethiopia holidays.

The changes to:

  1. Start year (1976) based on Negarit Gazeta Proclamation
  2. Addition of supported_categories with PUBLIC and WORKDAY
  3. Addition of en_ET to supported languages

All align well with the PR objectives of following official sources and adding workday categories.


45-45: Appropriate type hint addition.

Adding the return type hint to _is_leap_year method matches the base class implementation in holidays/holiday_base.py while maintaining consistency with other country implementations.


77-77: Good updates to holiday names with official translations.

The holiday names now use more descriptive Amharic strings that better reflect the official designations. This improves accuracy and authenticity of the Ethiopian holiday representations.

Also applies to: 80-81, 87-87, 90-91, 93-93, 96-96, 103-103, 106-106, 116-116, 119-120, 122-122


82-84: Correctly implemented year-specific holiday.

The Adwa Victory Day is now properly added only for years 1996 and later, which aligns with the official recognition of this holiday.


108-110: Good implementation of historical holiday.

Limiting the Popular Revolution Commemoration Day to years 1990 and earlier correctly reflects the historical period when this holiday was observed.


124-130: Good addition of workday holidays.

The new _populate_workday_holidays method properly implements:

  1. Ethiopian Martyrs' Day (February 20)
  2. Nations, Nationalities and Peoples Day (December 9) for years 2006 and later

This correctly implements the WORKDAY category holidays based on official sources.


149-150: Well-updated Islamic holiday dates.

The addition of actual dates for 2024 and 2025 Islamic holidays improves accuracy for upcoming years and aligns with the PR objective of adding Ethiopia's actual Islamic holidays.

Also applies to: 160-161, 170-171

tests/countries/test_ethiopia.py (6)

23-26: Good test setup updates.

The test setup correctly:

  1. Updates the year range to match the new start_year (1976)
  2. Adds the no_estimated_holidays instance for testing non-estimated Islamic holidays
  3. Adds the workday_holidays instance to test the new WORKDAY category

These changes ensure proper test coverage for all the updates in the Ethiopia class.


32-32: Appropriate update to no_holidays test.

The test now correctly includes both PUBLIC and WORKDAY categories when checking for absence of holidays before the start year.


44-48: Good year-specific holiday test.

The test for Adwa Victory Day properly verifies:

  1. The holiday is present from 1996 onwards
  2. The holiday is absent before 1996

This matches the implementation in the Ethiopia class.


165-171: Well-structured test for new workday holiday.

The test for Ethiopian Martyrs' Day correctly:

  1. Verifies presence in the workday category
  2. Verifies absence in the default (PUBLIC) category

This properly tests the category-specific implementation.


172-178: Thorough test for Nations, Nationalities and Peoples Day.

The test correctly verifies:

  1. Presence in workday category from 2006 onwards
  2. Absence in workday category before 2006
  3. Absence in the default (PUBLIC) category

This provides complete coverage for this year-specific workday holiday.


219-240: Excellent addition of en_ET localization test.

The new test for the en_ET locale properly verifies all holiday names in the Ethiopian English format. The test for "Ethiopian National Unity Day (Ethiopian Nations and Nationalities) Day" correctly maintains the exact official wording from government sources, including the apparent redundancy with "Day" appearing twice.

✨ Finishing Touches
  • 📝 Generate Docstrings

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share
🪧 Tips

Chat

There are 3 ways to chat with CodeRabbit:

  • Review comments: Directly reply to a review comment made by CodeRabbit. Example:
    • I pushed a fix in commit <commit_id>, please review it.
    • Generate unit testing code for this file.
    • Open a follow-up GitHub issue for this discussion.
  • Files and specific lines of code (under the "Files changed" tab): Tag @coderabbitai in a new review comment at the desired location with your query. Examples:
    • @coderabbitai generate unit testing code for this file.
    • @coderabbitai modularize this function.
  • PR comments: Tag @coderabbitai in a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples:
    • @coderabbitai gather interesting stats about this repository and render them as a table. Additionally, render a pie chart showing the language distribution in the codebase.
    • @coderabbitai read src/utils.ts and generate unit testing code.
    • @coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.
    • @coderabbitai help me debug CodeRabbit configuration file.

Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments.

CodeRabbit Commands (Invoked using PR comments)

  • @coderabbitai pause to pause the reviews on a PR.
  • @coderabbitai resume to resume the paused reviews.
  • @coderabbitai review to trigger an incremental review. This is useful when automatic reviews are disabled for the repository.
  • @coderabbitai full review to do a full review from scratch and review all the files again.
  • @coderabbitai summary to regenerate the summary of the PR.
  • @coderabbitai generate docstrings to generate docstrings for this PR.
  • @coderabbitai generate sequence diagram to generate a sequence diagram of the changes in this PR.
  • @coderabbitai resolve resolve all the CodeRabbit review comments.
  • @coderabbitai configuration to show the current CodeRabbit configuration for the repository.
  • @coderabbitai help to get help.

Other keywords and placeholders

  • Add @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.
  • Add @coderabbitai summary to generate the high-level summary at a specific location in the PR description.
  • Add @coderabbitai anywhere in the PR title to generate the title automatically.

Documentation and Community

  • Visit our Documentation for detailed information on how to use CodeRabbit.
  • Join our Discord Community to get help, request features, and share feedback.
  • Follow us on X/Twitter for updates and announcements.

@codecov
Copy link
Copy Markdown

codecov bot commented Apr 23, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 100.00%. Comparing base (ad51a04) to head (8591603).
Report is 1 commits behind head on dev.

Additional details and impacted files
@@            Coverage Diff            @@
##               dev     #2490   +/-   ##
=========================================
  Coverage   100.00%   100.00%           
=========================================
  Files          214       214           
  Lines        13527     13533    +6     
  Branches      1928      1929    +1     
=========================================
+ Hits         13527     13533    +6     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Copy link
Copy Markdown
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 2

📜 Review details

Configuration used: .coderabbit.yaml
Review profile: ASSERTIVE
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between ad51a04 and b187f98.

📒 Files selected for processing (8)
  • README.md (1 hunks)
  • holidays/countries/ethiopia.py (6 hunks)
  • holidays/locale/am/LC_MESSAGES/ET.po (2 hunks)
  • holidays/locale/ar/LC_MESSAGES/ET.po (1 hunks)
  • holidays/locale/en_ET/LC_MESSAGES/ET.po (1 hunks)
  • holidays/locale/en_US/LC_MESSAGES/ET.po (1 hunks)
  • snapshots/countries/ET_COMMON.json (1 hunks)
  • tests/countries/test_ethiopia.py (3 hunks)
🧰 Additional context used
🧠 Learnings (2)
holidays/locale/en_ET/LC_MESSAGES/ET.po (1)
Learnt from: KJhellico
PR: vacanza/holidays#2388
File: holidays/locale/en_CI/LC_MESSAGES/CI.po:88-88
Timestamp: 2025-03-30T18:25:07.087Z
Learning: In the holidays library, localization files have a specific structure: message comments are in standard English (en_US) describing the holiday, while actual translations (msgstr) should use the locale-specific terminology (e.g., en_CI for Ivory Coast English). For example, "Night of Power" in standard English is translated as "Lailatou-Kadr" in Ivory Coast English.
tests/countries/test_ethiopia.py (1)
Learnt from: PPsyrius
PR: vacanza/holidays#2416
File: tests/countries/test_turkmenistan.py:52-64
Timestamp: 2025-04-05T04:47:27.213Z
Learning: For holiday tests in the vacanza/holidays project, structure tests by individual holidays rather than by years. Each test method should focus on a specific holiday and test it across multiple years (from start_year through 2050) using helper methods like `assertHolidayName`. For fixed holidays, use generators like `(f"{year}-01-01" for year in range(1991, 2051))`. For movable holidays, specify individual dates for specific years followed by a range check.
🧬 Code Graph Analysis (1)
tests/countries/test_ethiopia.py (2)
holidays/countries/ethiopia.py (2)
  • Ethiopia (24-130)
  • ET (133-134)
tests/common.py (7)
  • CommonCountryTests (356-374)
  • TestCase (28-338)
  • assertAliases (121-130)
  • assertNoHolidays (292-294)
  • assertHolidayName (195-199)
  • assertNoHolidayName (273-275)
  • assertLocalizedHolidays (327-338)
🔇 Additional comments (27)
README.md (1)

504-505: Updated country information for Ethiopia looks good.

The changes accurately reflect the expanded language support (adding en_ET) and holiday category (WORKDAY) mentioned in the PR objectives. This keeps the README in sync with the actual code implementation.

holidays/locale/en_ET/LC_MESSAGES/ET.po (3)

13-29: Well-structured file header with appropriate metadata.

The file header contains all the necessary metadata for the new en_ET locale including proper versioning, creation dates, and translator information. Good approach establishing this as a separate locale file for Ethiopian English.


30-33: Proper handling of estimated date format.

Correctly preserves the format string placeholder for estimated dates while translating the supplementary text.


35-93: Holiday translations appear accurate and consistent.

The translations from Amharic to English (Ethiopian variant) are well-structured and maintain consistent naming patterns for the standard holidays. These match the official source naming patterns mentioned in the PR description.

holidays/locale/am/LC_MESSAGES/ET.po (3)

17-27: Updated metadata for Amharic locale file.

Properly updated version information and translator details to match the current release.


35-92: Enhanced holiday name formalizations in Amharic.

The changes add more descriptive and formal names to the holiday entries, often adding "በዓል" (meaning festival/holiday) to maintain consistency. These updates match the official naming approach described in the PR.


94-100: New holiday entries added for completeness.

Added entries for Ethiopian Martyrs' Day ("የሰማዕታት ቀን") and Nations, Nationalities and Peoples Day ("የብሔር ብሔረሰቦች ቀን") as specified in the PR objectives.

holidays/locale/en_US/LC_MESSAGES/ET.po (3)

17-27: Updated metadata for en_US locale file.

Properly updated version information and translator details to match the current release.


39-93: Refined English holiday name translations.

The changes refine English translations to better match the corresponding Amharic terms, such as changing "Epiphany Day" to "Epiphany" and updating "Workers' Day" to "International Workers' Day". These changes improve consistency and accuracy.


94-100: Added translations for new holidays.

Successfully added translations for Ethiopian Martyrs' Day and Nations, Nationalities and Peoples Day, completing the localization for the newly added holidays.

holidays/locale/ar/LC_MESSAGES/ET.po (4)

17-27: Updated metadata looks good.

The version and timestamp updates accurately reflect the PR's changes. Good job keeping the metadata in sync.


35-40: Christmas and Epiphany Arabic translations improved.

The more descriptive Amharic strings now have better Arabic translations that include cultural context.


54-60: Good addition of formalized holiday names.

The International Workers' Day and Ethiopian Patriots' Victory Day translations are appropriate and consistent with the full official names.


94-100: New workday holiday translations added correctly.

The Ethiopian Martyrs' Day and Nations, Nationalities and Peoples Day translations have been properly added to match the WORKDAY category additions in the main module.

snapshots/countries/ET_COMMON.json (4)

3-5: Correct holidays standardization and addition.

The renamed "Epiphany" and new "Ethiopian Martyrs' Day" entries correctly follow the naming standards established in the Ethiopia module.


8-11: Renamed holidays match module changes.

The standardized "International Workers' Day" and "Ethiopian Patriots' Victory Day" names are consistent with the Ethiopia module updates.


426-426: Nations, Nationalities and Peoples Day correctly starts from 2006.

The first occurrence of this holiday in 2006 aligns with the condition in the Ethiopia module.


690-694: 2024 Islamic holiday dates added correctly.

The updated Eid al-Adha and Prophet's Birthday dates for 2024 match the constants added to the EthiopiaIslamicHolidays class.

holidays/countries/ethiopia.py (5)

17-20: Appropriate imports for new functionality.

Added missing calendar month constant and the PUBLIC/WORKDAY category constants needed for the expanded functionality.


40-43: Good standardization of data sources and supported features.

  • Setting start_year to 1976 based on the Negarit Gazeta Proclamation
  • Adding WORKDAY category alongside PUBLIC
  • Including en_ET as a supported language

These changes properly align with the official sources mentioned in the documentation.


82-84: Historically accurate holiday condition.

Adding the year >= 1996 condition for Adwa Victory Day correctly reflects its official recognition date.


124-130: Well-structured workday holidays method.

The new _populate_workday_holidays method cleanly implements the two workday-specific holidays with appropriate year conditions.


149-171: Updated Islamic holiday dates.

The additions for 2024-2025 Islamic holidays keep the calendar current and accurate.

tests/countries/test_ethiopia.py (4)

23-26: Good test setup with specialized instances.

The setup now includes:

  • Updated year range matching the module's start_year
  • A separate instance for testing non-estimated Islamic holidays
  • A dedicated instance for testing WORKDAY category holidays

This approach provides thorough test coverage for all functionality.


46-49: Proper year-specific holiday testing.

The Adwa Victory Day test correctly verifies that the holiday exists from 1996 onward and doesn't exist before then.


168-181: Comprehensive tests for new workday holidays.

The tests for Ethiopian Martyrs' Day and Nations, Nationalities and Peoples Day properly verify:

  1. They exist in the workday_holidays instance
  2. They have the correct dates and year ranges
  3. They don't appear in the default PUBLIC category

This provides complete coverage of the new WORKDAY category holidays.


222-243: Well-implemented en_ET localization test.

The new test for the en_ET locale properly verifies all the holiday translations, including the longer multi-line string for Nations, Nationalities and Peoples Day.

Copy link
Copy Markdown
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

📜 Review details

Configuration used: .coderabbit.yaml
Review profile: ASSERTIVE
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between ad51a04 and b187f98.

📒 Files selected for processing (8)
  • README.md (1 hunks)
  • holidays/countries/ethiopia.py (6 hunks)
  • holidays/locale/am/LC_MESSAGES/ET.po (2 hunks)
  • holidays/locale/ar/LC_MESSAGES/ET.po (1 hunks)
  • holidays/locale/en_ET/LC_MESSAGES/ET.po (1 hunks)
  • holidays/locale/en_US/LC_MESSAGES/ET.po (1 hunks)
  • snapshots/countries/ET_COMMON.json (1 hunks)
  • tests/countries/test_ethiopia.py (3 hunks)
🧰 Additional context used
🧠 Learnings (1)
tests/countries/test_ethiopia.py (1)
Learnt from: PPsyrius
PR: vacanza/holidays#2416
File: tests/countries/test_turkmenistan.py:52-64
Timestamp: 2025-04-05T04:47:27.213Z
Learning: For holiday tests in the vacanza/holidays project, structure tests by individual holidays rather than by years. Each test method should focus on a specific holiday and test it across multiple years (from start_year through 2050) using helper methods like `assertHolidayName`. For fixed holidays, use generators like `(f"{year}-01-01" for year in range(1991, 2051))`. For movable holidays, specify individual dates for specific years followed by a range check.
⏰ Context from checks skipped due to timeout of 300000ms (1)
  • GitHub Check: Test build on windows-latest
🔇 Additional comments (38)
holidays/locale/en_US/LC_MESSAGES/ET.po (5)

17-27: Updated metadata correctly.

The file has been updated with the correct version number and latest revision date, maintaining consistency with the project's versioning and documentation standards.


35-41: Improved holiday name consistency.

Holiday names have been updated with more descriptive Amharic versions, and the English translations have been standardized. The change from "Epiphany Day" to just "Epiphany" matches common international usage.


54-60: More accurate holiday name translations.

The change to "International Workers' Day" and "Ethiopian Patriots' Victory Day" provides more precise translations that better reflect the official names of these holidays in Ethiopia.


74-76: Clarified historical holiday name.

"Popular Revolution Commemoration Day" is a more accurate translation than the previous simpler name, providing better historical context for this holiday.


94-100: Successfully added new holidays.

Ethiopian Martyrs' Day and Nations, Nationalities and Peoples Day have been correctly added with appropriate translations, matching the holiday additions in the Ethiopia class.

holidays/countries/ethiopia.py (10)

17-20: LGTM: Import updates support new holiday categories.

Added the MAR month constant and PUBLIC/WORKDAY constants to support the expanded holiday types and date ranges.


27-34: Updated references with official sources.

References have been enhanced with links to official proclamations and additional resources, providing better documentation for the holiday implementations.


40-43: Start year adjustment aligns with official documentation.

Setting the start year to 1976 based on the Negarit Gazeta Proclamation No. 16/1975 is historically accurate and ensures that the holiday data begins with officially documented dates.


43-43: Added support for multiple languages including Ethiopian English.

The addition of "en_ET" to supported languages matches the new locale file and provides better support for Ethiopian-specific English translations.


45-45: Added return type annotation for better type safety.

Adding the -> bool return type annotation to _is_leap_year improves code clarity and enables better type checking.


76-122: Holiday names updated to official translations.

All holiday names have been updated with more descriptive Amharic versions that better match official naming conventions. The transition from "Workers' Day" to "International Workers' Day" and similar updates improve accuracy.


124-130: Successfully implemented workday holidays category.

The new _populate_workday_holidays method correctly implements the WORKDAY category with Ethiopian Martyrs' Day and conditional addition of Nations, Nationalities and Peoples Day from 2006 onward.


149-149: Updated Islamic holiday dates for 2024.

EID_AL_ADHA_DATES has been updated with the 2024 date, ensuring the calendar remains current.


160-160: Added 2025 date for Eid al-Fitr.

EID_AL_FITR_DATES dictionary has been updated with the 2025 date, providing forward compatibility.


170-170: Added 2024 date for Mawlid.

MAWLID_DATES has been updated with the 2024 date, ensuring the calendar covers upcoming holidays.

holidays/locale/en_ET/LC_MESSAGES/ET.po (5)

1-29: Successfully added Ethiopian English locale.

The new en_ET locale file has been properly set up with complete metadata, including appropriate headers and generator information. The X-Source-Language tag correctly identifies Amharic as the source language.


35-54: Appropriate Ethiopian English translations.

The translations correctly use Ethiopia-specific terminology, such as "Christmas Holiday" instead of "Christmas Day" and "Easter" instead of "Easter Sunday", reflecting local usage.


67-70: Added culturally specific translation.

The Ethiopian New Year translation includes the indigenous name "Enkutatash" in parentheses, providing cultural context while maintaining clarity.


71-74: Used local terminology for Meskel.

Using "Meskel Holiday" instead of "Finding of True Cross" reflects Ethiopian English usage and makes the holiday more recognizable to locals.


91-94: Simplified Prophet's Birthday to Mawlid.

Using the term "Mawlid" instead of "Prophet's Birthday" aligns with local Ethiopian English usage for this Islamic holiday.

holidays/locale/ar/LC_MESSAGES/ET.po (5)

17-27: Updated Arabic locale metadata.

The file has been correctly updated with the latest version number and revision date to maintain consistency with other locale files.


35-41: Enhanced Arabic translations with cultural context.

The updated translations now include original holiday names in parentheses (like "جنا" for Christmas and "طمقت" for Epiphany), providing better cultural context and recognition.


54-60: Standardized international holiday names.

"International Workers' Day" and "Ethiopian Patriots' Victory Day" have been appropriately translated to their standard Arabic equivalents, maintaining consistency with international naming conventions.


67-72: Added indigenous terms to translations.

Including the indigenous terms "إنكوتاتاش" (Enkutatash) for New Year and "مسقل" (Meskel) for the Finding of True Cross improves cultural authenticity of the translations.


94-100: Added translations for new holidays.

The Arabic translations for Ethiopian Martyrs' Day and Nations, Nationalities and Peoples Day have been successfully added, completing the localization for all holidays.

README.md (1)

504-505: Good addition of en_ET locale and WORKDAY category

The update to include "en_ET" in the supported languages list and adding "WORKDAY" to supported categories for Ethiopia aligns with the broader implementation changes in the PR.

holidays/locale/am/LC_MESSAGES/ET.po (3)

17-19: Metadata updates look good

The version upgrade from 0.44 to 0.72 and update to the revision date reflects the changes made in this PR.


35-44: Culturally accurate holiday names

The renaming of holidays to include "በዓል" (holiday/festival) provides more culturally accurate and complete names in Amharic.


94-96: New holiday additions complete the implementation

The addition of the two new holidays ("የሰማዕታት ቀን" and "የብሔር ብሔረሰቦች ቀን") ensures consistency with the broader changes in the Ethiopia holiday class.

snapshots/countries/ET_COMMON.json (4)

4-5: Ethiopian Martyrs' Day correctly set as a recurring holiday

The Ethiopian Martyrs' Day has been properly added as a recurring holiday on February 20th starting from 1976.


8-9: Renamed to International Workers' Day for accuracy

Renaming "Workers' Day" to "International Workers' Day" provides a more accurate and official naming convention.


425-426: Nations, Nationalities and Peoples Day correctly implemented

The new holiday "Nations, Nationalities and Peoples Day" has been properly added starting from 2006, which aligns with its official introduction.


690-694: Updated Islamic holidays for 2024

The Islamic holidays (Eid al-Adha, Mawlid) have been updated for 2024, ensuring accuracy for upcoming years.

tests/countries/test_ethiopia.py (5)

15-16: Good import of category constants

Adding the import of PUBLIC and WORKDAY constants is necessary for the updated category tests.


23-26: Well-structured test setup with category filtering

Creating separate instances for no-estimated holidays and workday-only holidays improves test clarity and coverage.


168-173: Proper testing of category-specific holiday

The test for Ethiopian Martyrs' Day correctly verifies it appears only in the WORKDAY category and not in the default category set.


175-181: Good temporal boundary testing

The test for Nations, Nationalities and Peoples Day correctly verifies it appears only from 2006 onward in the WORKDAY category and not in the default category set.


222-243: Comprehensive testing of new locale

The test for the en_ET locale thoroughly checks all holiday translations, including the more detailed name for National Unity Day.

@PPsyrius PPsyrius marked this pull request as ready for review April 23, 2025 10:03
@KJhellico KJhellico changed the title Update Ethiopia holidays: official source namings, WORKDAY category. Update Ethiopia holidays: official source namings, WORKDAY category Apr 23, 2025
@sonarqubecloud
Copy link
Copy Markdown

Copy link
Copy Markdown
Collaborator

@KJhellico KJhellico left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

Copy link
Copy Markdown
Collaborator

@arkid15r arkid15r left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@arkid15r arkid15r added this pull request to the merge queue Apr 23, 2025
Merged via the queue into vacanza:dev with commit 787dbf3 Apr 23, 2025
33 checks passed
@PPsyrius PPsyrius deleted the eth_2025 branch April 23, 2025 16:02
@arkid15r arkid15r mentioned this pull request May 5, 2025
@coderabbitai coderabbitai bot mentioned this pull request Jul 9, 2025
9 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants