Skip to content

feat: add Konkani locale parity - #1780

Merged
clairernovotny merged 3 commits into
mainfrom
feat-kok
May 16, 2026
Merged

feat: add Konkani locale parity#1780
clairernovotny merged 3 commits into
mainfrom
feat-kok

Conversation

@clairernovotny

Copy link
Copy Markdown
Member

Summary

  • Add full generated locale data for Konkani (kok) across formatter, phrases, number words/parsing, ordinal, clock, compass, calendar, and numeric formatting surfaces.
  • Add kok exact-output tests and sweep/matrix coverage for locale parity.

Validation

  • dotnet test tests/Humanizer.SourceGenerators.Tests/Humanizer.SourceGenerators.Tests.csproj --framework net10.0
  • dotnet test tests/Humanizer.Tests/Humanizer.Tests.csproj --framework net10.0
  • dotnet test tests/Humanizer.Tests/Humanizer.Tests.csproj --framework net8.0
  • dotnet test tests/Humanizer.Tests/Humanizer.Tests.csproj --framework net11.0
  • dotnet pack src/Humanizer/Humanizer.csproj -c Release -o artifacts/locale-parity-validation -p:UseSharedCompilation=false -m:1
  • dotnet format Humanizer.slnx --verify-no-changes --verbosity minimal

Copilot AI review requested due to automatic review settings May 16, 2026 19:50
@chatgpt-codex-connector

Copy link
Copy Markdown

Codex usage limits have been reached for code reviews. Please check with the admins of this repo to increase the limits by adding credits.
Repo admins can enable using credits for code reviews in their settings.

@coderabbitai

coderabbitai Bot commented May 16, 2026

Copy link
Copy Markdown

Review Change Stack

Note

Reviews paused

It looks like this branch is under active development. To avoid overwhelming you with review comments due to an influx of new commits, CodeRabbit has automatically paused this review. You can configure this behavior by changing the reviews.auto_review.auto_pause_after_reviewed_commits setting.

Use the following commands to manage reviews:

  • @coderabbitai resume to resume automatic reviews.
  • @coderabbitai review to trigger a single review.

Use the checkboxes below for quick actions:

  • ▶️ Resume reviews
  • 🔍 Trigger review
📝 Walkthrough

Walkthrough

Adds full Konkani (kok) locale: a comprehensive YAML locale file, many new expected rows across localization test matrices and docs, plus a new KonkaniLocaleTests suite exercising localization surfaces.

Changes

Konkani Locale Support

Layer / File(s) Summary
Konkani locale YAML configuration
src/Humanizer/Locales/kok.yml
Defines the complete Konkani locale with relative date phrases, duration templates, time and data unit names, number-to-words mappings (cardinal/ordinal with gender variants), numeric formatting/parsing rules, date patterns, clock notation setup, compass directions, and month names.
Konkani test data matrices
docs/localization.md, tests/Humanizer.Tests/Localisation/LocaleCoverageData.cs, LocaleFormatterExactTheoryData.cs, LocaleNumberMagnitudeTheoryData.cs, LocaleNumberOverloadTheoryData.cs, LocaleNumberTheoryData.cs, LocaleOrdinalizerMatrixData.cs, LocalePhraseTheoryData.cs
Extends existing localization TheoryData datasets with Konkani expectations: ordinal dates, clock times (exact and rounded), relative phrases, time-span humanization, cardinal/ordinal numbers with gender and word-form variants, words-to-number mappings, magnitudes and overload cases, and formatter exact cases; also updates supported-locales count in docs.
Konkani integration test suite
tests/Humanizer.Tests/Localisation/kok/KonkaniLocaleTests.cs
New KonkaniLocaleTests class validating Konkani localization across list formatting, date/time phrases, durations, number-to-words and parsing, ordinal words (gendered), exact DateTime/DateOnly ordinals and clock notation, compass directions, and numeric/metric separators.

Estimated code review effort

🎯 4 (Complex) | ⏱️ ~45 minutes

Possibly related PRs

Poem

I stitched my words in YAML night,
Konkani hops into the light,
Dates and digits snug and neat,
Clocks and compass find their beat,
A rabbit hums: locale complete 🐇✨

🚥 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 The title clearly and concisely summarizes the main change: adding Konkani locale support to achieve parity.
Description check ✅ Passed The description is directly related to the changeset, providing a clear summary of changes, validation steps, and objectives.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.

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

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch feat-kok

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

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Pull request overview

Adds Konkani (kok) locale parity by introducing locale YAML data and broad test matrix coverage across formatting, number words/parsing, ordinalization, dates, clocks, compass headings, and numeric formatting.

Changes:

  • Added kok.yml locale definitions for generated Humanizer surfaces.
  • Added Konkani-specific exact-output tests.
  • Extended shared locale theory/matrix data with kok rows.

Reviewed changes

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

Show a summary per file
File Description
src/Humanizer/Locales/kok.yml Defines Konkani locale surfaces and generated profiles.
tests/Humanizer.Tests/Localisation/kok/KonkaniLocaleTests.cs Adds locale-specific exact-output tests.
tests/Humanizer.Tests/Localisation/LocaleCoverageData.cs Adds kok rows for shared coverage datasets.
tests/Humanizer.Tests/Localisation/LocaleFormatterExactTheoryData.cs Adds formatter exact-output rows.
tests/Humanizer.Tests/Localisation/LocaleNumberTheoryData.cs Adds number words, ordinal, gender, and parsing rows.
tests/Humanizer.Tests/Localisation/LocaleNumberOverloadTheoryData.cs Adds overload test rows for large numbers.
tests/Humanizer.Tests/Localisation/LocaleNumberMagnitudeTheoryData.cs Adds magnitude coverage rows.
tests/Humanizer.Tests/Localisation/LocaleOrdinalizerMatrixData.cs Adds ordinalizer matrix rows.
tests/Humanizer.Tests/Localisation/LocalePhraseTheoryData.cs Adds relative phrase and duration rows.
Comments suppressed due to low confidence (2)

src/Humanizer/Locales/kok.yml:702

  • The feminine numeric ordinalizer is missing the exact forms for 19 and 30, so it falls back to cardinal+suffix (एकोणीसवी/तीसवी) instead of the number.words.ordinal forms एकोणीसावी/तिसावी.
          20: 'विसावी'
          21: 'एकविसावी'
          32: 'बत्तीसावी'
          100: 'शंबरावी'

src/Humanizer/Locales/kok.yml:719

  • The neuter numeric ordinalizer is missing the exact forms for 19 and 30. This makes the fallback output एकोणीसवें/तीसवें, which disagrees with the number.words.ordinal forms एकोणीसावें/तिसावें.
          20: 'विसावें'
          21: 'एकविसावें'
          32: 'बत्तीसावें'
          100: 'शंबरावें'

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

Comment thread src/Humanizer/Locales/kok.yml
Comment thread tests/Humanizer.Tests/Localisation/LocaleOrdinalizerMatrixData.cs
Copilot AI review requested due to automatic review settings May 16, 2026 20:29

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Pull request overview

Copilot reviewed 9 out of 9 changed files in this pull request and generated 1 comment.

Comment thread src/Humanizer/Locales/kok.yml
Copilot AI review requested due to automatic review settings May 16, 2026 21:04

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Pull request overview

Copilot reviewed 10 out of 10 changed files in this pull request and generated 1 comment.

Comment thread docs/localization.md Outdated
Copilot AI review requested due to automatic review settings May 16, 2026 21:28

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Pull request overview

Copilot reviewed 10 out of 10 changed files in this pull request and generated no new comments.

@clairernovotny
clairernovotny merged commit 7c8d703 into main May 16, 2026
8 checks passed
@clairernovotny
clairernovotny deleted the feat-kok branch May 16, 2026 22:30
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.

2 participants