Skip to content

Update United States holidays: add Good Friday, Christmas Eve, New Year's Eve to UNOFFICIAL category#3324

Merged
arkid15r merged 8 commits into
vacanza:devfrom
PPsyrius:US_unofficial
Mar 24, 2026
Merged

Update United States holidays: add Good Friday, Christmas Eve, New Year's Eve to UNOFFICIAL category#3324
arkid15r merged 8 commits into
vacanza:devfrom
PPsyrius:US_unofficial

Conversation

@PPsyrius

Copy link
Copy Markdown
Collaborator

Proposed change

  • Add "Good Friday", "Christmas Eve", "New Year's Eve" to the United States UNOFFICIAL category holidays list.
  • Refactor for United States holidays test cases and their dependencies/territories.

Resolves #3323 .

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

coderabbitai Bot commented Mar 12, 2026

Copy link
Copy Markdown
Contributor

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: ASSERTIVE

Plan: Pro

Run ID: 7186e6a4-cd93-433b-8ae6-cbc5ef0fdc5f

📥 Commits

Reviewing files that changed from the base of the PR and between 5d6ec27 and 6ca4f76.

📒 Files selected for processing (6)
  • holidays/countries/united_states.py
  • holidays/locale/en_US/LC_MESSAGES/US.po
  • holidays/locale/th/LC_MESSAGES/US.po
  • snapshots/countries/US_MA.json
  • tests/countries/test_puerto_rico.py
  • tests/countries/test_united_states.py

Summary by CodeRabbit

  • New Features

    • Good Friday, Easter Sunday, Christmas Eve, and New Year's Eve added across US calendars and territories.
    • Many dates now show combined observance labels and half-day closing notes.
    • Holiday coverage extended through 2050 for states and territories.
  • Localization

    • Added Easter Sunday to translation catalogs; new Thai translation included.

Walkthrough

Adds unofficial Easter-related and year‑end observances (Good Friday, Easter Sunday, Christmas Eve, New Year's Eve) to UnitedStates and injects corresponding date mappings and composite labels into many snapshot JSON locale files through 2050; also updates PO metadata and adds an Easter Sunday translation.

Changes

Cohort / File(s) Summary
US source
holidays/countries/united_states.py
Inserted unofficial holiday additions into _populate_unofficial_holidays: Good Friday, Easter Sunday, Christmas Eve, New Year's Eve (gated by year check and inline comments).
US state snapshots
snapshots/countries/US_*.json, snapshots/countries/US_AK.json, snapshots/countries/US_AL.json, snapshots/countries/US_AR.json, snapshots/countries/US_AS.json, snapshots/countries/US_AZ.json, snapshots/countries/US_CA.json, snapshots/countries/US_CO.json
Bulk data insertions for Good Friday, Easter Sunday, Christmas Eve, New Year's Eve across many years; many entries converted to composite labels (e.g., "Christmas Day (observed); Christmas Eve", "New Year's Day (observed); New Year's Eve") and half‑day variants.
US territory / common snapshots
snapshots/countries/AS_COMMON.json, snapshots/countries/GU_COMMON.json, snapshots/countries/MP_COMMON.json, snapshots/countries/PR_COMMON.json, snapshots/countries/UM_COMMON.json
Added Easter and year‑end holiday entries and composite labels across multi‑year ranges; expanded date maps with Good Friday, Easter Sunday, Christmas Eve, New Year's Eve.
Locale files
holidays/locale/en_US/LC_MESSAGES/US.po, holidays/locale/th/LC_MESSAGES/US.po
Updated PO headers and added a new message entry/translation for "Easter Sunday".

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~25 minutes

Possibly related PRs

Suggested reviewers

  • arkid15r
🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (4 passed)
Check name Status Explanation
Title check ✅ Passed Title directly and specifically summarizes the main change: adding Good Friday, Christmas Eve, and New Year's Eve to UNOFFICIAL holidays for United States.
Description check ✅ Passed Description clearly relates to the changeset, outlining the addition of three holidays to UNOFFICIAL category and refactoring of test cases.
Linked Issues check ✅ Passed PR satisfies issue #3323 requirements: adds Good Friday, Christmas Eve, and New Year's Eve to United States holidays, making them available when including Government and Unofficial categories.
Out of Scope Changes check ✅ Passed All changes are scoped to adding the three requested holidays to UNOFFICIAL category, updating snapshots accordingly, and minor test/locale refactoring. No unrelated changes detected.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

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

Comment @coderabbitai help to get the list of available commands and usage tips.

@codecov

codecov Bot commented Mar 12, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 100.00%. Comparing base (27f4956) to head (6ca4f76).
⚠️ Report is 3 commits behind head on dev.

Additional details and impacted files
@@            Coverage Diff            @@
##               dev     #3324   +/-   ##
=========================================
  Coverage   100.00%   100.00%           
=========================================
  Files          310       310           
  Lines        18580     18585    +5     
  Branches      2379      2380    +1     
=========================================
+ Hits         18580     18585    +5     

☔ 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.

@Ryderjj89

Copy link
Copy Markdown

Does this include Easter Sunday as well?

@PPsyrius

Copy link
Copy Markdown
Collaborator Author

Does this include Easter Sunday as well?

No, but I can include that as well

Comment thread tests/countries/test_united_states.py
PPsyrius and others added 3 commits March 14, 2026 18:15
@PPsyrius

Copy link
Copy Markdown
Collaborator Author

I'm sorry for the forced git push, but that should fix our weird git merge issue earlier

Comment thread tests/countries/test_northern_mariana_islands.py
@PPsyrius PPsyrius requested a review from KJhellico March 23, 2026 09:44
@sonarqubecloud

Copy link
Copy Markdown

@KJhellico KJhellico left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

LGTM! 👍

@arkid15r arkid15r left a comment

Copy link
Copy Markdown
Collaborator

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 Mar 24, 2026
Merged via the queue into vacanza:dev with commit bd01922 Mar 24, 2026
32 checks passed
@PPsyrius PPsyrius deleted the US_unofficial branch March 24, 2026 03:16
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.

United States missing holidays

4 participants