Skip to content

fix(sdk): correct broken AndroidX package entries and add CI validation guard#23175

Merged
MartinZikmund merged 6 commits into
masterfrom
dev/agzi/fix-android-packages-and-guard
May 2, 2026
Merged

fix(sdk): correct broken AndroidX package entries and add CI validation guard#23175
MartinZikmund merged 6 commits into
masterfrom
dev/agzi/fix-android-packages-and-guard

Conversation

@agneszitte

@agneszitte agneszitte commented May 1, 2026

Copy link
Copy Markdown
Member

Related to https://github.com/unoplatform/uno-private/issues/1126.
Related to https://github.com/unoplatform/uno-private/issues/1327.
Related to https://github.com/unoplatform/uno-private/issues/1328.

Summary

Fixes 3 broken AndroidX package entries in src/Uno.Sdk/packages.json that were introduced in PR #23157, and adds a CI validation guard to prevent future recurrences.

What

  • Xamarin.AndroidX.Car.AppXamarin.AndroidX.Car.App.App — the package ID was wrong (correct NuGet ID has the extra .App suffix). Updated in packages.json, Uno.Implicit.Packages.ProjectSystem.Android.targets, Sdk.props.buildschema.json, and doc/articles/features/android-auto.md.
  • Xamarin.AndroidX.Wear net10.0 override 1.3.0.171.4.0.1 — version 1.3.0.17 does not exist on NuGet.org
  • Xamarin.AndroidX.Wear.Tiles base 1.4.0.21.4.0.1, net10.0 1.4.0.31.4.1 — both original versions do not exist on NuGet.org
  • Added build/ci/scripts/validate-packages-json.ps1 — a PowerShell script that validates all package ID + version pairs in packages.json exist on NuGet.org via the flat container API (with timeout, retry, deduplication, and release-branch detection via both BUILD_SOURCEBRANCH and SYSTEM_PULLREQUEST_TARGETBRANCH)
  • Integrated the guard into the Setup/Validations stage of the Azure DevOps CI pipeline (added src/Uno.Sdk/packages.json to sparse checkout)

Why

These broken entries cause NuGet restore failures for any downstream consumer enabling AndroidAuto or Wear features, including new Uno.Sdk packages publication

(Issue caught after on uno.templates with the help of previous fix(ci): block nuget publish on missing dependencies#2009)

The CI guard prevents this class of issue from reaching master in the future.

Validation

Ran validate-packages-json.ps1 locally — all 122 package/version combinations now pass:

Checked 122 package/version combinations. All packages validated successfully.

Related to previous PR: #23157

Copilot AI review requested due to automatic review settings May 1, 2026 17:48
@github-actions github-actions Bot added area/build Categorizes an issue or PR as relevant to build infrastructure area/sdk Categorizes an issue or PR as relevant to the Uno.Sdk labels May 1, 2026
…on guard

- Fix Xamarin.AndroidX.Car.App → Xamarin.AndroidX.Car.App.App (wrong package ID)
- Fix Xamarin.AndroidX.Wear net10.0 override 1.3.0.17 → 1.4.0.1 (non-existent version)
- Fix Xamarin.AndroidX.Wear.Tiles base 1.4.0.2 → 1.4.0.1, net10.0 1.4.0.3 → 1.4.1 (non-existent versions)
- Add validate-packages-json.ps1 CI guard that checks all NuGet entries exist
- Integrate guard into Setup/Validations stage of Azure DevOps pipeline

These broken entries were introduced in PR #23157 and block downstream consumers
(e.g. uno.toolkit.ui PR #2072) from resolving packages on net10.0-android.

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

Fixes invalid AndroidX package ID/version entries in src/Uno.Sdk/packages.json and introduces an Azure DevOps CI guard that validates all packages.json package ID + version combinations exist on NuGet.org.

Changes:

  • Correct AndroidX package IDs/versions for Car App, Wear, and Wear Tiles in src/Uno.Sdk/packages.json.
  • Add build/ci/scripts/validate-packages-json.ps1 to validate package/version existence via NuGet flat container.
  • Wire the validation script into the CI Setup/Validations stage via a new YAML template.

Reviewed changes

Copilot reviewed 4 out of 4 changed files in this pull request and generated 3 comments.

File Description
src/Uno.Sdk/packages.json Fixes broken AndroidX package ID/version pins (incl. net10 overrides).
build/ci/setup/.azure-devops-setup-validate-packages.yml Adds a CI step template to run the validation script.
build/ci/scripts/validate-packages-json.ps1 Implements NuGet.org existence checks for all package/version pairs in packages.json.
build/ci/.azure-devops-stages.yml Integrates the new validation template into the Setup/Validations job.
Comments suppressed due to low confidence (1)

src/Uno.Sdk/packages.json:288

  • packages.json now pins the Android Auto package as Xamarin.AndroidX.Car.App.App, but the SDK still references Xamarin.AndroidX.Car.App elsewhere (e.g., src/Uno.Sdk/targets/Uno.Implicit.Packages.ProjectSystem.Android.targets and the UnoFeatures buildschema description). As-is, enabling AndroidAuto will continue to request the old (broken) package ID even though the version pinning has been corrected here. Update the implicit PackageReference include(s) (and any related descriptions) to use Xamarin.AndroidX.Car.App.App so restore succeeds end-to-end.
		"packages": [
			"Xamarin.AndroidX.Car.App.App"
		],
		"versionOverride": {
			"net10.0": "1.4.0.3"
		}

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

Comment thread build/ci/.azure-devops-stages.yml
Comment thread build/ci/scripts/validate-packages-json.ps1 Outdated
Comment thread build/ci/.azure-devops-stages.yml

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

Fixes invalid AndroidX entries in Uno.Sdk’s packages.json and adds an Azure DevOps validation step to ensure all package ID/version pairs listed there exist on NuGet.org, preventing restore-breaking pins from landing again.

Changes:

  • Correct AndroidX package IDs/versions in src/Uno.Sdk/packages.json (Car App + Wear + Wear Tiles).
  • Add build/ci/scripts/validate-packages-json.ps1 to validate packages.json entries against NuGet’s flat container API.
  • Wire the validation script into the Azure DevOps Setup/Validations stage (and adjust sparse checkout to include src/Uno.Sdk/**).

Reviewed changes

Copilot reviewed 4 out of 4 changed files in this pull request and generated 3 comments.

File Description
src/Uno.Sdk/packages.json Fixes broken AndroidX package ID/version entries.
build/ci/scripts/validate-packages-json.ps1 New CI guard script validating package existence on NuGet.org.
build/ci/setup/.azure-devops-setup-validate-packages.yml Adds a pipeline step to run the validation script.
build/ci/.azure-devops-stages.yml Integrates the new validation template and expands sparse checkout to include Uno.Sdk.

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

Comment thread build/ci/.azure-devops-stages.yml
Comment thread src/Uno.Sdk/packages.json
Comment thread build/ci/scripts/validate-packages-json.ps1
@agneszitte
agneszitte requested a review from Copilot May 1, 2026 18:11
- Pass BUILD_SOURCEBRANCH env var from pipeline to script
- Auto-detect release/* branches and switch to warning-only mode
- Warnings shown in yellow but build not failed on stable branches

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

This PR corrects invalid AndroidX entries in src/Uno.Sdk/packages.json and introduces a CI validation step to ensure all packages.json package ID + version pairs exist on NuGet.org, preventing future restore breaks from non-existent pins.

Changes:

  • Fix AndroidX package ID/version pins in src/Uno.Sdk/packages.json (Car App, Wear, Wear Tiles).
  • Add validate-packages-json.ps1 and wire it into Azure DevOps Setup/Validations.
  • Update CI sparse checkout patterns so src/Uno.Sdk/packages.json is available to the validation job.

Reviewed changes

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

File Description
src/Uno.Sdk/packages.json Corrects AndroidX package IDs/versions used by the SDK’s package pinning.
build/ci/setup/.azure-devops-setup-validate-packages.yml Adds an Azure DevOps step template to run the NuGet existence validation.
build/ci/scripts/validate-packages-json.ps1 Implements the NuGet flat-container existence check for all entries in packages.json.
build/ci/.azure-devops-stages.yml Integrates the new validation template and ensures src/Uno.Sdk/** is included in sparse checkout.

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

Comment thread src/Uno.Sdk/packages.json
Comment thread build/ci/scripts/validate-packages-json.ps1
…idation script

- Update Uno.Implicit.Packages.ProjectSystem.Android.targets to use
  Xamarin.AndroidX.Car.App.App (matching packages.json fix)
- Update Sdk.props.buildschema.json description accordingly
- Add -TimeoutSec 30, -MaximumRetryCount 3, -RetryIntervalSec 2 to
  NuGet HTTP requests in validate-packages-json.ps1
- De-duplicate package+version pairs to avoid redundant API calls
@agneszitte
agneszitte requested a review from Copilot May 1, 2026 18:24
@agneszitte
agneszitte requested review from Copilot and removed request for Copilot May 1, 2026 18:32

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

Fixes invalid AndroidX package ID/version entries in the Uno.Sdk package manifest and adds an Azure DevOps validation step to prevent publishing packages.json entries that don’t exist on NuGet.org.

Changes:

  • Correct Android Auto implicit package ID (Xamarin.AndroidX.Car.App.App) and update corresponding packages.json entry.
  • Fix invalid AndroidX Wear / Wear Tiles versions in packages.json.
  • Add and wire a CI PowerShell guard (validate-packages-json.ps1) into the Setup/Validations stage (with sparse checkout update).

Reviewed changes

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

Show a summary per file
File Description
src/Uno.Sdk/targets/Uno.Implicit.Packages.ProjectSystem.Android.targets Fixes the Android Auto implicit PackageReference ID used for project system/design-time restore.
src/Uno.Sdk/packages.json Corrects broken AndroidX package IDs/versions so restore can succeed.
src/Uno.Sdk/Sdk/Sdk.props.buildschema.json Updates the UnoFeatures schema description to reflect the corrected package ID.
build/ci/setup/.azure-devops-setup-validate-packages.yml Adds a new CI step template to run the NuGet existence validation script.
build/ci/scripts/validate-packages-json.ps1 Implements validation of all packages.json package/version pairs against NuGet flat container.
build/ci/.azure-devops-stages.yml Integrates the validation template and adjusts sparse checkout to include Uno.Sdk content.

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

Comment thread build/ci/scripts/validate-packages-json.ps1 Outdated
Comment thread build/ci/.azure-devops-stages.yml Outdated

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

Fixes invalid AndroidX implicit-package entries in the Uno.Sdk package pinning and adds an Azure DevOps CI guard to prevent packages.json from containing NuGet IDs/versions that don’t exist on NuGet.org.

Changes:

  • Correct Xamarin.AndroidX.Car.AppXamarin.AndroidX.Car.App.App across SDK targets, package pins, buildschema metadata, and docs.
  • Fix nonexistent AndroidX Wear / Wear.Tiles version pins and net10.0 overrides in src/Uno.Sdk/packages.json.
  • Add and wire up a CI validation step that checks packages.json package/version existence against NuGet.org during Setup/Validations (including updating sparse checkout to include src/Uno.Sdk/**).

Reviewed changes

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

Show a summary per file
File Description
src/Uno.Sdk/targets/Uno.Implicit.Packages.ProjectSystem.Android.targets Align AndroidAuto implicit project-system package reference with the corrected AndroidX Car App NuGet ID.
src/Uno.Sdk/packages.json Fix broken/nonexistent AndroidX package IDs and version pins (including net10.0 overrides).
src/Uno.Sdk/Sdk/Sdk.props.buildschema.json Update UnoFeatures description string to reference the corrected Car App package ID.
doc/articles/features/android-auto.md Update documentation to reference the corrected Car App package ID.
build/ci/setup/.azure-devops-setup-validate-packages.yml Add a CI step template to run packages.json NuGet existence validation.
build/ci/scripts/validate-packages-json.ps1 New validation script: parses packages.json, deduplicates checks, adds timeout/retry, and supports release-branch warning-only mode.
build/ci/.azure-devops-stages.yml Integrate the new validation step and include src/Uno.Sdk/** in sparse checkout so the validator can read packages.json.

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

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 7 out of 7 changed files in this pull request and generated no new comments.


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

@unodevops

Copy link
Copy Markdown
Contributor

🤖 Your WebAssembly Skia Sample App stage site is ready! Visit it here: https://unowasmprstaging.z20.web.core.windows.net/pr-23175/wasm-skia-net9/index.html

@agneszitte
agneszitte requested a review from ajpinedam May 1, 2026 19:09

@ajpinedam ajpinedam 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.

Looks good! Nice

Comment thread src/Uno.Sdk/Sdk/Sdk.props.buildschema.json
@MartinZikmund
MartinZikmund merged commit 58b7246 into master May 2, 2026
69 checks passed
@MartinZikmund
MartinZikmund deleted the dev/agzi/fix-android-packages-and-guard branch May 2, 2026 05:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area/build Categorizes an issue or PR as relevant to build infrastructure area/sdk Categorizes an issue or PR as relevant to the Uno.Sdk kind/documentation

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants