Skip to content

Update India holidays: add TG as subdivision alias for Telangana#3376

Merged
arkid15r merged 4 commits intovacanza:devfrom
Vikash-Kumar-23:add-tg-alias-telangana
Mar 23, 2026
Merged

Update India holidays: add TG as subdivision alias for Telangana#3376
arkid15r merged 4 commits intovacanza:devfrom
Vikash-Kumar-23:add-tg-alias-telangana

Conversation

@Vikash-Kumar-23
Copy link
Copy Markdown
Contributor

@Vikash-Kumar-23 Vikash-Kumar-23 commented Mar 23, 2026

Proposed change

This PR adds support for "TG" as an alias for Telangana ("TS") in the India holidays module.

Details
Maps subdiv="TG" to TS
Ensures India(subdiv="TG") behaves the same as India(subdiv="TS")
Keeps existing behavior unchanged

Why
In some contexts, Telangana is referred to as "TG" (e.g., recent government usage). Supporting it as an alias improves usability while still keeping "TS" as the primary ISO code.

Verification
India(subdiv="TG", years=2023) returns the same holidays as India(subdiv="TS", years=2023)
Existing subdivisions (e.g., "KA") continue to work as expected
Ran python -m unittest — all tests pass

Files changed
holidays/countries/india.py
README.md

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

Copilot AI review requested due to automatic review settings March 23, 2026 01:24
@coderabbitai
Copy link
Copy Markdown
Contributor

coderabbitai Bot commented Mar 23, 2026

Walkthrough

Added the subdivision alias "TG" → "TS" for Telangana in the India provider, updated the README "Available Countries" table to include TG as an alias for TS (Telangana), and added two reference links to the India class docstring.

Changes

Cohort / File(s) Summary
README update
README.md
Updated "Available Countries" table entry for India to list TS (TG, Telangana, Telangāna) instead of TS (Telangana, Telangāna).
India provider alias & docs
holidays/countries/india.py
Added "TG" → "TS" to India.subdivisions_aliases and appended two reference links in the class docstring; no holiday computation changes.
Contributors list
CONTRIBUTORS
Inserted contributor name Vikash Kumar into the contributors list.

Estimated code review effort

🎯 1 (Trivial) | ⏱️ ~3 minutes

Possibly related PRs

Suggested reviewers

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

❌ Failed checks (1 inconclusive)

Check name Status Explanation Resolution
Linked Issues check ❓ Inconclusive The PR partially addresses issue #3232 by adding TG as an alias for Telangana, but does not implement the full scope of adding Telangana-specific holidays (Bathukamma, Bonalu, Telangana Formation Day). Clarify whether this PR is intended as an interim step toward full Telangana holiday support or if the alias addition alone satisfies issue #3232's requirements.
✅ Passed checks (4 passed)
Check name Status Explanation
Out of Scope Changes check ✅ Passed Changes are narrowly scoped to adding the TG alias and updating documentation; contributor credit addition is standard practice and not out of scope.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Title check ✅ Passed The title directly describes the main change: adding 'TG' as a subdivision alias for Telangana in India holidays, which aligns with the primary modification in the codebase.
Description check ✅ Passed The pull request description clearly outlines the purpose, scope, and verification of the changes—adding TG as an alias for Telangana in the India holidays module.

✏️ 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
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Adds support for using "TG" as an alias subdivision code for Telangana ("TS") in the India holiday provider, and documents the alias in the README.

Changes:

  • Add "TG" -> "TS" mapping in India.subdivisions_aliases so India(subdiv="TG") routes to the Telangana subdivision holiday population.
  • Update the README country table to list "TG" as an alias for Telangana ("TS").

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 3 comments.

File Description
holidays/countries/india.py Adds "TG" subdivision alias mapping to the existing Telangana ("TS") subdivision.
README.md Documents "TG" as an alias under the India → Telangana ("TS") entry.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread holidays/countries/india.py
Comment thread README.md
Comment thread holidays/countries/india.py
Copy link
Copy Markdown
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.

Where exactly does this "TG" code came from? I don't recall seeing this in the ISO 3166-2:IN https://www.iso.org/obp/ui/#iso:code:3166:IN

@PPsyrius PPsyrius changed the title Add TG as alias for Telangana (TS) Update India holidays: add TG as subdivision_aliases for Telangana Mar 23, 2026
@codecov
Copy link
Copy Markdown

codecov Bot commented Mar 23, 2026

Codecov Report

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

Additional details and impacted files
@@            Coverage Diff            @@
##               dev     #3376   +/-   ##
=========================================
  Coverage   100.00%   100.00%           
=========================================
  Files          310       310           
  Lines        18580     18580           
  Branches      2379      2379           
=========================================
  Hits         18580     18580           

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

Comment thread holidays/countries/india.py
Comment thread holidays/countries/india.py Outdated
PPsyrius
PPsyrius previously approved these changes Mar 23, 2026
Copy link
Copy Markdown
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 🇮🇳

Feel free to add your name to the CONTRIBUTORS file as well as part of this PR

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

@KJhellico KJhellico changed the title Update India holidays: add TG as subdivision_aliases for Telangana Update India holidays: add TG as subdivision alias for Telangana Mar 23, 2026
@KJhellico
Copy link
Copy Markdown
Collaborator

@Vikash-Kumar-23, the initial issue #3232 primarily concerns Telangana holidays, rather than the state code. Therefore, it would be incorrect to consider this PR, in its current form, as resolving that issue.

@Vikash-Kumar-23
Copy link
Copy Markdown
Contributor Author

Vikash-Kumar-23 commented Mar 23, 2026

@KJhellico You're right — this PR only adds TG as a subdivision alias and does not address the Telangana holidays themselves.

I’ll update the PR description to avoid linking it to #3232 and keep this change scoped to alias support only.

For the missing Telangana holidays, I can open a separate PR if that would be helpful.

Does that approach sound good?

@KJhellico
Copy link
Copy Markdown
Collaborator

Does that approach sound good?

Yes.

@arkid15r arkid15r added this pull request to the merge queue Mar 23, 2026
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.

@Vikash-Kumar-23 thanks for the contribution!

Merged via the queue into vacanza:dev with commit 19d38ac Mar 23, 2026
32 checks passed
@coderabbitai coderabbitai Bot mentioned this pull request Mar 24, 2026
9 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants