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

Add Sri Lanka holidays #2228

Merged
merged 33 commits into from
Feb 1, 2025
Merged

Add Sri Lanka holidays #2228

merged 33 commits into from
Feb 1, 2025

Conversation

Prateekshit73
Copy link
Contributor

Proposed change

Added Sri Lanka holidays
Closes #1272

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

Copy link

codecov bot commented Jan 14, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 100.00%. Comparing base (4526e2a) to head (8b034f6).
Report is 1 commits behind head on dev.

Additional details and impacted files
@@            Coverage Diff             @@
##               dev     #2228    +/-   ##
==========================================
  Coverage   100.00%   100.00%            
==========================================
  Files          196       199     +3     
  Lines        11935     12134   +199     
  Branches      1722      1731     +9     
==========================================
+ Hits         11935     12134   +199     

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

Makefile Outdated Show resolved Hide resolved
This reverts commit 8b59449.
Copy link
Collaborator

@PPsyrius PPsyrius left a comment

Choose a reason for hiding this comment

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

Nice to see new country being added 🚀

Makefile Outdated Show resolved Hide resolved
holidays/locale/en_US/LC_MESSAGES/LK.po Outdated Show resolved Hide resolved
holidays/locale/ta_LK/LC_MESSAGES/LK.po Outdated Show resolved Hide resolved
holidays/locale/si_LK/LC_MESSAGES/LK.po Outdated Show resolved Hide resolved
holidays/countries/sri_lanka.py Outdated Show resolved Hide resolved
holidays/countries/sri_lanka.py Outdated Show resolved Hide resolved
@PPsyrius
Copy link
Collaborator

I'm working up a solution for Poya Day calculations at the moment and will create a suggestion PR with them later - I was originally planned to base them on Thai LuniSolar calendar ones but it appears the results aren't a 100% match yet

@Prateekshit73
Copy link
Contributor Author

I'm working up a solution for Poya Day calculations at the moment and will create a suggestion PR with them later - I was originally planned to base them on Thai LuniSolar calendar ones but it appears the results aren't a 100% match yet

If there's anything I can do to assist you with the Poya Day calculations, please let me know. I’d be more than happy to help out in any way I can!

@arkid15r
Copy link
Collaborator

@PPsyrius anything we should wait from you or this is good for review?

@PPsyrius
Copy link
Collaborator

@arkid15r no, many poya days assignments are still incorrect at the moment

@Prateekshit73
Copy link
Contributor Author

Thanks for the update, @PPsyrius! If there's anything specific you'd like me to look into, just let me know. I'm happy to contribute!

@Prateekshit73
Copy link
Contributor Author

For full coverage it's required to execute a branch where maha_sivarathri_date is None. But there is no such case in years range 2003-2025 (defined by start_year/end_year values for LK).

Hi Sir @KJhellico,

Thank you for your insights! Given that maha_sivarathri_date is never None for the years 2003-2025, do you think it would be feasible to change the start_year to a year before 2003? This could help us create a test case that triggers the branch where maha_sivarathri_date is None, allowing us to achieve full coverage.

As a referenced in the code itself, Sri Lanka's Holidays Act (No. 29 of 1971) was first proclaimed on September 2nd, 1971, which might provide context for setting the start_year.

@KJhellico
Copy link
Collaborator

`Sri Lanka's Holidays Act (No. 29 of 1971) was first proclaimed on September 2nd, 1971

Then I think it's better to pick 1972 as start_year.

PPsyrius
PPsyrius previously approved these changes Jan 29, 2025
Copy link
Collaborator

@PPsyrius PPsyrius left a comment

Choose a reason for hiding this comment

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

LGTM 🇱🇰

KJhellico
KJhellico previously approved these changes Jan 29, 2025
Copy link
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!

@arkid15r arkid15r dismissed stale reviews from KJhellico and PPsyrius via 8b034f6 February 1, 2025 01:32
Copy link

sonarqubecloud bot commented Feb 1, 2025

Copy link
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.

Thanks for this amazing contribution @Prateekshit73 !

LGTM

@Prateekshit73
Copy link
Contributor Author

Thanks for this amazing contribution @Prateekshit73 !

I just initiated the PR; it was @PPsyrius, @KJhellico and you who made it work.

@arkid15r
Copy link
Collaborator

arkid15r commented Feb 1, 2025

Thanks for this amazing contribution @Prateekshit73 !

I just initiated the PR; it was @PPsyrius, @KJhellico and you who made it work.

Yep, those two are just awesome in terms of calendars/holidays work. We are so lucky to have them as a part of the team.

@arkid15r arkid15r added this pull request to the merge queue Feb 1, 2025
Merged via the queue into vacanza:dev with commit 39c4aa0 Feb 1, 2025
32 checks passed
@Prateekshit73 Prateekshit73 deleted the add-sri_lanka branch February 1, 2025 21:00
@arkid15r arkid15r mentioned this pull request Feb 3, 2025
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.

Add Sri Lanka holidays
4 participants