Skip to content

[build] Remove unused diagnostic resources - #13407

Merged
simonrozsival merged 3 commits into
dotnet:mainfrom
jonathanpeppers:jonathanpeppers-internal-diagnostic-cleanup
Nov 6, 2026
Merged

simonrozsival merged 3 commits into
dotnet:mainfrom
jonathanpeppers:jonathanpeppers-internal-diagnostic-cleanup

Conversation

@jonathanpeppers

Copy link
Copy Markdown
Member

Remove 36 unused diagnostic resource entries and their generated accessors to reduce unnecessary localization maintenance. Mark the corresponding retired diagnostics in the documentation while retaining historical pages.

All active messages remain localized. There are no product-code, target, or test changes. This addresses only the orphaned-resource portion of the issue.

Relates to #13196

Validation:

  • ./dotnet-local.sh build src/Xamarin.Android.Build.Tasks/Xamarin.Android.Build.Tasks.csproj --no-restore -v minimal - passed, 0 errors.
  • ./dotnet-local.sh test src/Xamarin.Android.Build.Tasks/Tests/Xamarin.Android.Build.Tests/Xamarin.Android.Build.Tests.csproj --no-restore -v minimal --filter 'FullyQualifiedName~CopyResourceTests|FullyQualifiedName~R8Tests' - passed, 34 tests.
  • ./dotnet-local.sh test src/Microsoft.Android.Build.Tasks/Tests/Microsoft.Android.Build.Tasks.Tests/Microsoft.Android.Build.Tasks.Tests.csproj -v minimal --filter 'FullyQualifiedName~GenerateR8JniRemappingTests|FullyQualifiedName~GenerateTypeMapProguardConfigurationTests|FullyQualifiedName~ExtractTypeMapKeysFrom|FullyQualifiedName~GenerateTrimmableTypeMapTests|FullyQualifiedName~WrapAssemblyStoresAsSharedLibrariesTests|FullyQualifiedName~GenerateNativeApplicationConfigSourcesTests|FullyQualifiedName~GenerateJniRemappingBinaryBlobsTests|FullyQualifiedName~NativeAotDataObject|FullyQualifiedName~CompressAssembliesTests' - passed, 421 tests.
  • XML/accessor comparison - exactly 36 matching removals; every retained resource unchanged.

Full SDK setup was attempted with make prepare && make all and make leeroy. Compilation succeeded, but both failed during workload setup because API 37 Mono.Android.xml was missing.

jonathanpeppers and others added 3 commits November 5, 2026 13:49
…ages

Keep diagnostic codes and failure behavior, preserve user-facing resources, and synchronize accessors, historical documentation, and regression coverage.

Co-authored-by: Copilot App <[email protected]>
Remove unnecessary test additions and repeated localization documentation. Use interpolation for non-localized messages and keep retired-code entries concise.

Co-authored-by: Copilot App <[email protected]>
Restore all active localized resources and diagnostic call sites. Keep only the 36 verified orphan removals and matching retired-code documentation.

Co-authored-by: Copilot App <[email protected]>
Copilot AI balanced review requested due to automatic review settings November 5, 2026 13:26

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.

🟢 Approval recommended

No active review issues are reported for the unused diagnostic resource cleanup.

No open issues 🎉

1 file not reviewed
  • src/Xamarin.Android.Build.Tasks/Properties/Resources.Designer.cs: Generated file
What changed in this PR

Removes unused diagnostic resources from the .NET for Android build tasks to reduce localization maintenance. This addresses the orphaned-resource portion of #13196; active messages remain localized.

Changes:

  • Removes 36 unused resource entries and their matching generated accessors.
  • Marks retired diagnostics in the documentation while preserving historical pages.
  • Leaves product logic, build targets, and tests unchanged.
File Description
src/​Xamarin.Android.Build.Tasks/​Properties/​Resources.resx Removes 36 unused diagnostic resources.
src/​Xamarin.Android.Build.Tasks/​Properties/​Resources.Designer.cs Removes the matching generated accessors.
Documentation/​docs-mobile/​messages/​xa5301.md Adds a retirement notice; preserves historical guidance.
Documentation/​docs-mobile/​messages/​xa4324.md Adds a retirement notice; preserves historical guidance.
Documentation/​docs-mobile/​messages/​xa4308.md Adds a retirement notice; preserves historical guidance.
Documentation/​docs-mobile/​messages/​xa4307.md Adds a retirement notice; preserves historical guidance.
Documentation/​docs-mobile/​messages/​xa4264.md Adds a retirement notice; preserves historical guidance.
Documentation/​docs-mobile/​messages/​xa4253.md Adds a retirement notice; preserves historical guidance.
Documentation/​docs-mobile/​messages/​xa4243.md Adds a retirement notice; preserves historical guidance.
Documentation/​docs-mobile/​messages/​xa4231.md Adds a retirement notice; preserves historical guidance.
Documentation/​docs-mobile/​messages/​xa4227.md Adds a retirement notice; preserves historical guidance.
Documentation/​docs-mobile/​messages/​xa4217.md Adds a retirement notice; preserves historical guidance.
Documentation/​docs-mobile/​messages/​xa4214.md Adds a retirement notice; preserves historical guidance.
Documentation/​docs-mobile/​messages/​xa2024.md Adds a retirement notice; preserves historical guidance.
Documentation/​docs-mobile/​messages/​xa0139.md Adds a retirement notice; preserves historical guidance.
Documentation/​docs-mobile/​messages/​xa0125.md Adds a retirement notice; preserves historical guidance.
Documentation/​docs-mobile/​messages/​xa0122.md Adds a retirement notice; preserves historical guidance.
Documentation/​docs-mobile/​messages/​xa0105.md Adds a retirement notice; preserves historical guidance.
Documentation/​docs-mobile/​messages/​index.md Marks corresponding diagnostic entries as no longer emitted.

Review effort: Balanced

@simonrozsival
simonrozsival enabled auto-merge (squash) November 6, 2026 11:48
@simonrozsival
simonrozsival merged commit a90ece0 into dotnet:main Nov 6, 2026
40 checks passed
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.

3 participants