Skip to content

Conversation

Copy link
Contributor

Copilot AI commented Jan 17, 2026

MLKit packages were generating inconsistent namespaces. The genai-prompt and genai-common packages used Google.MLKit.GenAI.* while existing MLKit packages used Xamarin.Google.MLKit.*.

Changes

Added namespace replacement rule in Directory.Build.props:

<AndroidNamespaceReplacement Include='com.google.mlkit' Replacement='Xamarin.Google.MLKit' />

Positioned before the general com.google.Google rule to ensure MLKit packages match the established pattern.

Impact

  • 36 MLKit packages now use consistent Xamarin.Google.MLKit.* namespace prefix
  • Fixes genai-prompt: com.google.mlkit.genai.promptXamarin.Google.MLKit.GenAI.Prompt
  • Fixes genai-common: com.google.mlkit.genai.commonXamarin.Google.MLKit.GenAI.Common
  • Fixes digital-ink packages to match convention

Note on GoogleGson

The com.google.code.gson package uses GoogleGson namespace without the Xamarin prefix. This is the only Google package (out of 258) with this inconsistency, but was left unchanged to avoid breaking published packages.

Original prompt

the genai-prompt package should have a Xamarin.Google.* namespace and not just the Google.* namespace. Can you fix that and check to make sure if there are others that are not consistent with the existing practice of prefixing Google with Xamarin.Google


💡 You can make Copilot smarter by setting up custom instructions, customizing its development environment and configuring Model Context Protocol (MCP) servers. Learn more Copilot coding agent tips in the docs.

Copilot AI changed the title [WIP] Fix namespace to use Xamarin.Google prefix Add namespace replacement rule for com.google.mlkit packages Jan 17, 2026
Copilot AI requested a review from mattleibow January 17, 2026 00:27
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