Skip to content

Update India holidays: add missing Mizoram state holidays#3388

Open
mengChengxi wants to merge 1 commit intovacanza:devfrom
mengChengxi:dev
Open

Update India holidays: add missing Mizoram state holidays#3388
mengChengxi wants to merge 1 commit intovacanza:devfrom
mengChengxi:dev

Conversation

@mengChengxi
Copy link

Proposed change

Closes #3380.
Added missing fixed-date public holidays for Mizoram (MZ) subdivision in India. These include Missionary Day (Jan 11), YMA Day (Jun 15), Remna Ni (Jun 30), and MHIP Day (Jul 6).
And, I also updated the 2018 snapshot tests and all localization test cases to ensure the project maintains 100% test coverage.

Your PR description goes here.

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
Contributor

coderabbitai bot commented Mar 24, 2026

Walkthrough

Adds four fixed-date Mizoram holidays (Missionary Day Jan 11, YMA Day Jun 15, Remna Ni Jun 30, MHIP Day Jul 6), updates India docstring reference, extends tests across multiple locales for 2018, and appends contributor Chengxi Meng to CONTRIBUTORS.

Changes

Cohort / File(s) Summary
Documentation
CONTRIBUTORS
Added contributor Chengxi Meng after Chanran Kim.
India Holiday Implementation
holidays/countries/india.py
Added four fixed-date Mizoram subdivision holidays and updated class docstring/reference.
Test Coverage
tests/countries/test_india.py
Expanded 2018 expectations and localization assertions to include the four new Mizoram holiday dates and names across multiple locale tests.

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~20 minutes

Possibly related PRs

Suggested labels

l10n

Suggested reviewers

  • arkid15r
  • KJhellico
  • PPsyrius
🚥 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
Description check ✅ Passed The description is directly related to the changeset, explaining the added holidays and updated tests for Mizoram.
Linked Issues check ✅ Passed The PR fulfills issue #3380 requirements by identifying, implementing, and testing Mizoram's missing fixed-date holidays from official sources.
Out of Scope Changes check ✅ Passed All changes are directly scoped to the objectives: adding Mizoram holidays, updating tests, adding contributor credit, with no extraneous modifications.
Title check ✅ Passed The title accurately captures the main change: adding missing Mizoram state holidays to the India holiday library.

✏️ 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.

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

🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Inline comments:
In `@holidays/countries/india.py`:
- Around line 42-43: In the Mizoram entry in india.py, remove the accidental
suffix "_populate_subdiv_mz_public_holidays" that was appended to the archived
URL so the citation URL is valid, and reformat the Mizoram block to match other
states by placing the source as a bulleted line (prefix with the same "* "
bullet and keep the URL in angle brackets with the trailing underscore for the
Sphinx-style reference) under the "Mizoram:" key; locate the "Mizoram:" entry in
the file to make this change.
- Around line 421-430: The new MZ holidays were added via _add_holiday_jan_11,
_add_holiday_feb_20, _add_holiday_jun_15, _add_holiday_jun_30 and
_add_holiday_jul_6 but the corresponding country snapshot (IN_MZ snapshot) and
India locale catalogs were not regenerated; run the repo's snapshot and
localization generators (make snapshot and make l10n) to update the IN_MZ
snapshot and India locale files so the four holidays are present in snapshots
and translation catalogs.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: ASSERTIVE

Plan: Pro

Run ID: 4edb41c6-fb54-4e76-b145-467248beeebc

📥 Commits

Reviewing files that changed from the base of the PR and between bd01922 and 2d8c974.

📒 Files selected for processing (3)
  • CONTRIBUTORS
  • holidays/countries/india.py
  • tests/countries/test_india.py

Comment on lines +42 to +43
Mizoram:
* <https://web.archive.org/web/20250114025233/https://dipr.mizoram.gov.in/page/government-holiday-2024>_populate_subdiv_mz_public_holidays
Copy link
Contributor

Choose a reason for hiding this comment

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

⚠️ Potential issue | 🟡 Minor

Fix the malformed Mizoram source reference.

Line 43 appends _populate_subdiv_mz_public_holidays to the URL, so the citation is malformed. Also keep Mizoram: aligned with the bullet style used for other states.

Suggested docstring fix
-        Mizoram:
-            * <https://web.archive.org/web/20250114025233/https://dipr.mizoram.gov.in/page/government-holiday-2024>_populate_subdiv_mz_public_holidays
+        * Mizoram:
+            * <https://web.archive.org/web/20250114025233/https://dipr.mizoram.gov.in/page/government-holiday-2024>
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
Mizoram:
* <https://web.archive.org/web/20250114025233/https://dipr.mizoram.gov.in/page/government-holiday-2024>_populate_subdiv_mz_public_holidays
* Mizoram:
* <https://web.archive.org/web/20250114025233/https://dipr.mizoram.gov.in/page/government-holiday-2024>
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@holidays/countries/india.py` around lines 42 - 43, In the Mizoram entry in
india.py, remove the accidental suffix "_populate_subdiv_mz_public_holidays"
that was appended to the archived URL so the citation URL is valid, and reformat
the Mizoram block to match other states by placing the source as a bulleted line
(prefix with the same "* " bullet and keep the URL in angle brackets with the
trailing underscore for the Sphinx-style reference) under the "Mizoram:" key;
locate the "Mizoram:" entry in the file to make this change.

Comment on lines +421 to +430
# Missionary Day.
self._add_holiday_jan_11(tr("Missionary Day"))
# Mizoram State Day.
self._add_holiday_feb_20(tr("Mizoram State Day"))
# YMA Day.
self._add_holiday_jun_15(tr("YMA Day"))
# Remna Ni.
self._add_holiday_jun_30(tr("Remna Ni"))
# MHIP Day.
self._add_holiday_jul_6(tr("MHIP Day"))
Copy link
Contributor

Choose a reason for hiding this comment

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

⚠️ Potential issue | 🟠 Major

🧩 Analysis chain

🏁 Script executed:

#!/bin/bash
set -euo pipefail

names=("Missionary Day" "YMA Day" "Remna Ni" "MHIP Day")

echo "== Snapshot check: snapshots/countries/IN_MZ.json =="
for n in "${names[@]}"; do
  echo "-- $n"
  rg -n --fixed-strings "$n" snapshots/countries/IN_MZ.json || true
done

echo
echo "== Locale catalog check: holidays/locale/*/LC_MESSAGES/IN.po =="
for n in "${names[@]}"; do
  echo "-- msgid \"$n\""
  rg -n --fixed-strings "msgid \"$n\"" holidays/locale/*/LC_MESSAGES/IN.po || true
done

Repository: vacanza/holidays

Length of output: 315


Sync snapshot and locale artifacts with the new MZ holidays.

The four holidays (Missionary Day, YMA Day, Remna Ni, MHIP Day) are missing from both snapshots/countries/IN_MZ.json and the India locale catalogs. Run make snapshot and make l10n to regenerate these artifacts so regression coverage is complete.

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@holidays/countries/india.py` around lines 421 - 430, The new MZ holidays were
added via _add_holiday_jan_11, _add_holiday_feb_20, _add_holiday_jun_15,
_add_holiday_jun_30 and _add_holiday_jul_6 but the corresponding country
snapshot (IN_MZ snapshot) and India locale catalogs were not regenerated; run
the repo's snapshot and localization generators (make snapshot and make l10n) to
update the IN_MZ snapshot and India locale files so the four holidays are
present in snapshots and translation catalogs.

@sonarqubecloud
Copy link

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

♻️ Duplicate comments (1)
holidays/countries/india.py (1)

42-43: ⚠️ Potential issue | 🟡 Minor

Fix malformed Mizoram reference URL.

Line 43 appends _populate_subdiv_mz_public_holidays to the archive URL, which breaks the citation format.

🛠️ Proposed fix
-        * Mizoram:
-            * <https://web.archive.org/web/20250114025233/https://dipr.mizoram.gov.in/page/government-holiday-2024>_populate_subdiv_mz_public_holidays>
+        * Mizoram:
+            * <https://web.archive.org/web/20250114025233/https://dipr.mizoram.gov.in/page/government-holiday-2024>
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@holidays/countries/india.py` around lines 42 - 43, The Mizoram archive URL in
holidays/countries/india.py is malformed because the trailing suffix
"_populate_subdiv_mz_public_holidays" was appended directly to the URL; locate
the line containing the fragment "_populate_subdiv_mz_public_holidays" and
remove that suffix so the archive link ends at the .gov.in URL, and if you
intended a reference label keep it as a separate footnote/reference (e.g., use
the proper reST/Markdown reference syntax) rather than attaching it to the URL.
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Duplicate comments:
In `@holidays/countries/india.py`:
- Around line 42-43: The Mizoram archive URL in holidays/countries/india.py is
malformed because the trailing suffix "_populate_subdiv_mz_public_holidays" was
appended directly to the URL; locate the line containing the fragment
"_populate_subdiv_mz_public_holidays" and remove that suffix so the archive link
ends at the .gov.in URL, and if you intended a reference label keep it as a
separate footnote/reference (e.g., use the proper reST/Markdown reference
syntax) rather than attaching it to the URL.

ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: ASSERTIVE

Plan: Pro

Run ID: a93df287-e875-41b9-bc5d-5a9245ce9742

📥 Commits

Reviewing files that changed from the base of the PR and between 2d8c974 and a63fd4e.

📒 Files selected for processing (3)
  • CONTRIBUTORS
  • holidays/countries/india.py
  • tests/countries/test_india.py

@mengChengxi
Copy link
Author

Hi @KJhellico @PPsyrius,

I noticed the heads-up from CodeRabbitAI! I've successfully implemented and verified the holiday logic for Mizoram (MZ) in india.py and aligned the 2018 tests.

However, I'm encountering some environment problems on my local mac (missing uv and l10n dependencies) which make me impossible to successfully run make l10n and regenerating the snapshot JSONs.

Since the core logic and manual test cases are solid, would you mind helping me trigger the snapshot/l10n regeneration upon merge? Or if there's a specific command I can use to let GitHub Actions handle the artifact updates, please let me know. I'm eager to learn the project's standard workflow!

@codecov
Copy link

codecov bot commented Mar 24, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 100.00%. Comparing base (bd01922) to head (a63fd4e).

Additional details and impacted files
@@            Coverage Diff            @@
##               dev     #3388   +/-   ##
=========================================
  Coverage   100.00%   100.00%           
=========================================
  Files          310       310           
  Lines        18585     18589    +4     
  Branches      2380      2380           
=========================================
+ Hits         18585     18589    +4     

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

@PPsyrius PPsyrius changed the title Fix: Add missing fixed-date public holidays for Mizoram (MZ) (#3380) Update India holidays: add missing Mizoram state holidays Mar 24, 2026
@PPsyrius PPsyrius mentioned this pull request Mar 24, 2026
9 tasks
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.

Note that India holidays implementation might be a bit overwhelming for first-time contributors (Public vs Restricted (OPTIONAL) holidays list, non-fixed calendars, lots of existing l10n support, etc)

Given your background, you might find implementing SSE or HKSE financial market holidays more approachable. That said, it will still require some research - see #3270 and #3271 for implemented examples.

* Gujarat:
* <https://web.archive.org/web/20260122052040/https://images-gujarati.indianexpress.com/2025/11/gujarat-government-Year-2026-holiday-list.pdf>
* Mizoram:
* <https://web.archive.org/web/20250114025233/https://dipr.mizoram.gov.in/page/government-holiday-2024>_populate_subdiv_mz_public_holidays>
Copy link
Collaborator

Choose a reason for hiding this comment

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

The reference you provide seems to be inaccessible - so I've replaced with ones with archive records from 2004-2024

Suggested change
* <https://web.archive.org/web/20250114025233/https://dipr.mizoram.gov.in/page/government-holiday-2024>_populate_subdiv_mz_public_holidays>
* <https://web.archive.org/web/20260324051214/http://mizoram.nic.in/gov/hols.htm>

Comment on lines 423 to 424
# Mizoram State Day.
self._add_holiday_feb_20(tr("Mizoram State Day"))
Copy link
Collaborator

Choose a reason for hiding this comment

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

Chapchar Kut seems to be missing here

Suggested change
# Mizoram State Day.
self._add_holiday_feb_20(tr("Mizoram State Day"))
# Mizoram State Day.
self._add_holiday_feb_20(tr("Mizoram State Day"))
# Chapchar Kut.
name = tr("Chapchar Kut")
if self._year >= 2011:
self._add_holiday_1st_fri_of_mar(name)
else:
self._add_holiday_2nd_fri_of_mar(name)

@mengChengxi
Copy link
Author

Note that India holidays implementation might be a bit overwhelming for first-time contributors (Public vs Restricted (OPTIONAL) holidays list, non-fixed calendars, lots of existing l10n support, etc)

Given your background, you might find implementing SSE or HKSE financial market holidays more approachable. That said, it will still require some research - see #3270 and #3271 for implemented examples.

Hi @PPsyrius, thank you for the guidance! You are right—diving straight into the complex variants and l10n integrations of the India module might be to hard for my first PR.

I really appreciate you pointing me towards the financial markets. Given my background, implementing the SSE (Shanghai Stock Exchange) calendar is a better starting point. I've already started reviewing the implementation patterns in #3270 and #3271. I will research the specific SSE closure rules and draft a PR.

Once I get familiar with the codebase through this, I'd love to circle back to the broader l10n architectural discussion (#1658). Thanks again for the mentorship!

@pareshjoshij
Copy link
Contributor

SSE or HKSE financial market holidays

@PPsyrius I'm actually doing some research on them right now and have a question:

When adding a new stock market, is the library's standard to start from ~2016, or should we aim to include deep historical data?

I ask because while cross-referencing the recent XETR addition with the official Deutsche Börse calendar, I noticed germany_exchange.py seems to be missing some historical dates, regional early-closes, and settlement-only days.

I dropped a message in the Slack group regarding the financial calendars. If you get some free time, I'd really appreciate your thoughts over there so I can guide my further research. Thanks !

@PPsyrius
Copy link
Collaborator

@pareshjoshij Ideally, we want to implement it as far as our reference sources are available - it's just that for our Germany Stock Exchange case, their per-year online record only went back that far, unlike the NYSE for example

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add missing public holidays for Indian subdivisions

3 participants