Skip to content

Fix Android CI build break in DI bootstrap path by adding missing AndroidX.Core reference#5

Merged
JusterZhu merged 2 commits intomainfrom
copilot/fix-ci-di-error
Mar 23, 2026
Merged

Fix Android CI build break in DI bootstrap path by adding missing AndroidX.Core reference#5
JusterZhu merged 2 commits intomainfrom
copilot/fix-ci-di-error

Conversation

Copy link
Copy Markdown
Contributor

Copilot AI commented Mar 23, 2026

The CI failure was caused by a compile-time namespace resolution error in the Android installer path used by the DI-registered bootstrap services. AndroidApkInstaller imports AndroidX.Core.Content.FileProvider, but the AndroidX Core package was not referenced by the Android library project.

  • What changed

    • Added a missing NuGet reference to Xamarin.AndroidX.Core in GeneralUpdate.Maui.Android.csproj.
    • Scoped the reference to Android targets only via MSBuild condition to avoid impacting non-Android builds.
  • Why this addresses the issue

    • Restores resolution of AndroidX.Core.Content used by AndroidApkInstaller, unblocking net10.0-android compilation in CI while keeping cross-target behavior unchanged.
  • Project file update

    <PackageReference Include="Xamarin.AndroidX.Core"
                      Version="1.13.1.1"
                      Condition="$([MSBuild]::GetTargetPlatformIdentifier('$(TargetFramework)')) == 'android'" />
Original prompt

This section details on the original issue you should resolve

<issue_title>CI/DI error</issue_title>
<issue_description>Please check the cause of the error and fix it.
https://github.com/GeneralLibrary/GeneralUpdate.Maui/actions/runs/23427212372/job/68144624765</issue_description>

<agent_instructions>Please check the cause of the error and fix it.</agent_instructions>

Comments on the Issue (you are @copilot in this section)


💡 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 CI/DI error in GeneralUpdate.Maui Fix Android CI build break in DI bootstrap path by adding missing AndroidX.Core reference Mar 23, 2026
Copilot AI requested a review from JusterZhu March 23, 2026 08:15
@JusterZhu JusterZhu marked this pull request as ready for review March 23, 2026 08:17
Copilot AI review requested due to automatic review settings March 23, 2026 08:17
@JusterZhu JusterZhu merged commit afa7181 into main Mar 23, 2026
@JusterZhu JusterZhu deleted the copilot/fix-ci-di-error branch March 23, 2026 08:17
Copy link
Copy Markdown

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

Fixes the Android-target build break in GeneralUpdate.Maui.Android by adding the missing AndroidX Core dependency required by the APK installer implementation, while keeping the non-Android target unaffected.

Changes:

  • Added a conditional PackageReference to Xamarin.AndroidX.Core for Android target builds only.

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

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.

CI/DI error

3 participants