Skip to content

beta to master#19461

Merged
seanbudd merged 1 commit into
masterfrom
beta
Jan 19, 2026
Merged

beta to master#19461
seanbudd merged 1 commit into
masterfrom
beta

Conversation

@seanbudd
Copy link
Copy Markdown
Member

No description provided.

was blocked by #19426 and #19458
Summary of the issue:

#19458 introduced Cambodian, but we need to document it's support in NVDA

Additionally, unit tests are temporarily broken by #19458 causing an issue, with python/cpython#123853 as the root cause
Description of user facing changes:

Document cambodian support
Description of developer facing changes:

None
Description of development approach:

    Introduced _LCIDS_TO_TRANSLATED_LOCALES_OVERRIDES in languageHandler.py to correctly map the Windows LCID for Khmer (Cambodian), addressing upstream issues in Python's locale mapping. [1] [2]
    Refactored type annotations throughout languageHandler.py to use modern Python syntax (e.g., str | None instead of Optional[str], list[str] instead of List[str]). [1] [2] [3] [4] [5] [6] [7] [8] [9] [10]
Copilot AI review requested due to automatic review settings January 19, 2026 03:18
@seanbudd seanbudd requested review from a team as code owners January 19, 2026 03:18
@seanbudd seanbudd merged commit cd0342e into master Jan 19, 2026
14 of 16 checks passed
@github-actions github-actions Bot added this to the 2026.2 milestone Jan 19, 2026
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

This pull request merges changes from the beta branch to master, primarily adding support for the Cambodian language translation to NVDA. The language count has been updated from 55 to 56 languages, and the implementation includes both documentation updates and code changes to handle the Cambodian locale correctly.

Changes:

  • Added Cambodian language translation support with proper LCID mapping
  • Updated documentation to reflect 56 supported languages
  • Modernized type hints from typing module to built-in Python 3.10+ syntax

Reviewed changes

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

File Description
user_docs/en/userGuide.md Updated language count from 55 to 56 and added Cambodian to the list of supported languages
user_docs/en/changes.md Added release notes documenting the new Cambodian translation
source/languageHandler.py Added LCID override for Cambodian (km_KH), updated copyright year to 2026, and modernized type hints to use built-in types

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

Comment thread source/languageHandler.py


def getLanguageDescription(language: str) -> Optional[str]:
def getLanguageDescription(language: str) -> weakref.ReferenceType | None:
Copy link

Copilot AI Jan 19, 2026

Choose a reason for hiding this comment

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

The return type annotation is incorrect. This function returns strings (e.g., at line 157 it returns _("User default") which is a string, and at line 179 it returns desc which is also a string). The type hint should be str | None, not weakref.ReferenceType | None. This appears to be an accidental error when updating the type hints from Optional[str] to modern syntax.

Suggested change
def getLanguageDescription(language: str) -> weakref.ReferenceType | None:
def getLanguageDescription(language: str) -> str | None:

Copilot uses AI. Check for mistakes.
@github-actions github-actions Bot requested a deployment to snapshot January 19, 2026 05:54 Abandoned
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