Skip to content

Fix NonShipping casing for Xamarin.Android.Tools.AndroidSdk package#11281

Open
jonathanpeppers wants to merge 1 commit intomainfrom
jonathanpeppers/fix-nonshipping-casing
Open

Fix NonShipping casing for Xamarin.Android.Tools.AndroidSdk package#11281
jonathanpeppers wants to merge 1 commit intomainfrom
jonathanpeppers/fix-nonshipping-casing

Conversation

@jonathanpeppers
Copy link
Copy Markdown
Member

@jonathanpeppers jonathanpeppers commented May 4, 2026

Description

darc gather-drop was downloading the Xamarin.Android.Tools.AndroidSdk package as if it were a "shipping" package, even though it was intended to be non-shipping.

The root cause is a casing mismatch in ManifestArtifactData. We had Nonshipping=true (lowercase 's'), but Arcade's ArtifactModel.NonShipping property looks up the key using nameof(NonShipping) (capital 'S'). During the build, this worked because MSBuildListSplitter.GetNamedProperties() creates a case-insensitive dictionary. However, when the manifest XML is later parsed back (by PublishBuildAssets to register in BAR, or by darc gather-drop), CreateAttributeDictionary() creates a case-sensitive dictionary, so the lookup for "NonShipping" fails to find "Nonshipping" and defaults to false (i.e., shipping).

Changes

  • Fixed casing: Nonshipping=true -> NonShipping=true
  • Removed the unused IsShipping="false" metadata, which is not read by Arcade's PackageArtifactModelFactory

Checklist

  • Useful description of why the change is necessary.
  • Links to issues fixed
  • Unit tests: N/A -- build infrastructure metadata fix

The ManifestArtifactData had "Nonshipping=true" (lowercase s), but
Arcade's ArtifactModel.NonShipping property looks up "NonShipping"
(capital S). During build, this worked because MSBuildListSplitter
creates a case-insensitive dictionary. However, when the manifest XML
is parsed back (by PublishBuildAssets or darc gather-drop),
CreateAttributeDictionary() creates a case-sensitive dictionary, so the
lookup fails and defaults to false (shipping).

Also removed the unused IsShipping="false" metadata, which is not read
by PackageArtifactModelFactory.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Copilot AI review requested due to automatic review settings May 4, 2026 18:42
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 PR fixes packaging metadata for the Xamarin.Android.Tools.AndroidSdk NuGet so Arcade/BAR consumers classify it as non-shipping consistently during manifest round-trips.

Changes:

  • Corrects ManifestArtifactData from Nonshipping=true to NonShipping=true.
  • Removes the redundant IsShipping="false" metadata from the special-case ItemsToPush entry.
  • Keeps the existing packaging flow unchanged aside from the non-shipping classification fix for this package.

@jonathanpeppers
Copy link
Copy Markdown
Member Author

@jonathanpeppers jonathanpeppers marked this pull request as draft May 5, 2026 13:36
@jonathanpeppers jonathanpeppers marked this pull request as ready for review May 5, 2026 16:15
@jonathanpeppers jonathanpeppers added the ready-to-review This PR is ready to review/merge, I think any CI failures are just flaky (ignorable). label May 5, 2026
@jonathanpeppers
Copy link
Copy Markdown
Member Author

jonathanpeppers commented May 5, 2026

I queued the above build with pushXAPackagesToMaestro=false, because I didn't want it to publish packages.

Unfortunately, that is the only way to test, so I think we should just merge to test.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ready-to-review This PR is ready to review/merge, I think any CI failures are just flaky (ignorable).

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants