Repository navigation
Missing androidx.window.[extensions|sidecar] warnings #6809
Description
Activity
- addedArea: App+Library BuildIssues when building Library projects or Application projects.Issues when building Library projects or Application projects.needs-triageIssues that need to be assigned.Issues that need to be assigned.
on Mar 4, 2022 I've already reported this some time ago via #6375, the app still works for me even if you see the messages.
I also see those
XA4218warnings that I think have nor seen before in VS 17.0
Also, deploying an app to the simulator becomes a gamble. 90% of the times when I change my .xml files (e.g. styles.xml) and try to build+deploy the app, if fails with:========== Build: 1 succeeded, 0 failed, 0 up-to-date, 0 skipped ========== ========== Deploy: 0 succeeded, 1 failed, 0 skipped ==========I also see those
XA4218warnings that I think have nor seen before in VS 17.0yes, this is new, but I also get it in VS2019 16.11.10 and started since last AndroidX Nuget updates from end of last week.
@jpobst / @moljac would you know if there is something new about these libraries?
Warning Unable to find //manifest/application/uses-library at path: C:\Program Files (x86)\Android\android-sdk\platforms\android-31\optional\androidx.window.sidecar.jar OBDNowPros C:\ProjectsVS2022Preview\Android12Pros\OBDNowPro\obj\Release\120\android\AndroidManifest.xml Warning Unable to find //manifest/application/uses-library at path: C:\Program Files (x86)\Android\android-sdk\platforms\android-31\optional\androidx.window.extensions.jar OBDNowPros C:\ProjectsVS2022Preview\Android12Pros\OBDNowPro\obj\Release\120\android\AndroidManifest.xml Warning Missing class androidx.window.extensions.WindowExtensions (referenced from: androidx.window.extensions.embedding.ActivityEmbeddingComponent androidx.window.embedding.EmbeddingCompat$Companion.embeddingComponent() and 3 other contexts) OBDNowPros C:\ProjectsVS2022Preview\Android12Pros\OBDNowPro\R8 Warning XA4218: Unable to find //manifest/application/uses-library at path: C:\Program Files (x86)\Android\android-sdk\platforms\android-31\optional\androidx.window.sidecar.jar 0 Warning XA4218: Unable to find //manifest/application/uses-library at path: C:\Program Files (x86)\Android\android-sdk\platforms\android-31\optional\androidx.window.extensions.jarWould these be something new where you define
<uses-library>for these in yourAndroidManifest.xml? We might need to add some build-time support for this.- removedneeds-triageIssues that need to be assigned.Issues that need to be assigned.
on Mar 7, 2022 Also, deploying an app to the simulator becomes a gamble. 90% of the times when I change my .xml files (e.g. styles.xml) and try to build+deploy the app, if fails with:
========== Build: 1 succeeded, 0 failed, 0 up-to-date, 0 skipped ========== ========== Deploy: 0 succeeded, 1 failed, 0 skipped ==========We are tracking this in #6652. The IDE team have an internal ticket which they are working on. I'll keep #6652 as up to date as I can.
@conceptdev Would you be so kind and help? Do you have any experience with this?
@jpobst / @moljac would you know if there is something new about these libraries?
Warning Unable to find //manifest/application/uses-library at path: C:\Program Files (x86)\Android\android-sdk\platforms\android-31\optional\androidx.window.sidecar.jar OBDNowPros C:\ProjectsVS2022Preview\Android12Pros\OBDNowPro\obj\Release\120\android\AndroidManifest.xml Warning Unable to find //manifest/application/uses-library at path: C:\Program Files (x86)\Android\android-sdk\platforms\android-31\optional\androidx.window.extensions.jar OBDNowPros C:\ProjectsVS2022Preview\Android12Pros\OBDNowPro\obj\Release\120\android\AndroidManifest.xml Warning Missing class androidx.window.extensions.WindowExtensions (referenced from: androidx.window.extensions.embedding.ActivityEmbeddingComponent androidx.window.embedding.EmbeddingCompat$Companion.embeddingComponent() and 3 other contexts) OBDNowPros C:\ProjectsVS2022Preview\Android12Pros\OBDNowPro\R8 Warning XA4218: Unable to find //manifest/application/uses-library at path: C:\Program Files (x86)\Android\android-sdk\platforms\android-31\optional\androidx.window.sidecar.jar 0 Warning XA4218: Unable to find //manifest/application/uses-library at path: C:\Program Files (x86)\Android\android-sdk\platforms\android-31\optional\androidx.window.extensions.jarWould these be something new where you define
<uses-library>for these in yourAndroidManifest.xml? We might need to add some build-time support for this.I cannot find these types in any of Google's AndroidX packages:
androidx.window.extensions.WindowExtensionsandroidx.window.extensions.embedding.ActivityEmbeddingComponent
But the latest releases of AndroidX do now generally have a dependency on
AndroidX.Window(viaXamarin.AndroidX.SlidingPaneLayout).Reacted by MagicAndre1981It's my understanding that the sidecar and extensions code are what we ship on device (ie. Surface Duo), to provide the OEM-specific implementation of the Window Manager dual-screen/foldable API surface. Other OEMS (like Samsung) would ship their own packages (again, in their OS).
Android native (Kotlin/Java) apps that consume AndroidX Window Manager do not reference these libraries via gradle. Not sure where these warnings are coming from in Xamarin.Android.
On maven.google.com I don't see corresponding packages there either.
@jpobst do any of the
.aarfiles contain anAndroidManifest.xmlfile with new<uses-library/>entries?23 remaining items
We could remove these warnings, but I'm not sure that's the right path.
I would not do that. Warnings are not caused by us.
These libraries are passed to d8/r8 as a "reference" and they don't get included on the app. They are normally libraries that OEMs provide on certain devices. If we had them we could solve the
XA4218warning, and the d8/r8 warning.I found one library:
This leads to correct official location
https://maven.google.com/web/index.html?q=androidx.window#androidx.window:window-extensions
Are we supposed to be using this somehow? It's only in alpha.
No. It was bound when
androidx.window.*was in preview for Screen Duo work, but not touched/updated afterwards.https://github.com/xamarin/AndroidX/blob/main/config.json#L1325-L1348
see my comment:
the warnings are still present in Visual Studio Version 17.3.0 Preview 6.0
the warnings are still present in Visual Studio Version 17.3.0 Preview 6.0
Thanks for the feedback, but Visual Studio version has nothing to do with this issue.
See: #6809 (comment)
Reacted by MagicAndre1981- changed the title
[-]VS2022 17.2.0 Preview 1.0 – Warnings not seen before.[/-][+]Missing `androidx.window.[extensions|sidecar]` warnings[/+]on Sep 14, 2022 I still get all the same warnings as to when I first reported it. I'm now using VS2022 17.3.0 Prev 1.1
These warnings are coming from AndroidX (
Xamarin.AndroidX.Window), VS updates will not fix it.I have the same warnings after upgrading the project to a newer Xamarin version using VS 17.5.2. I didn't have the
Xamarin.AndroidX.Windowpackage installed but still I got the errors. After installing this package just to test there were no changes in the build output log.Both warnings are still present after migrating a Xamarin.Android app to .NET 8
- added 4 commits that reference this issue
on Jul 8, 2024 - added a commit that references this issue
on Jul 19, 2024 - locked and limited conversation to collaborators
on Aug 19, 2024
Android application type
Classic Xamarin.Android (MonoAndroid12.0, etc.)
Affected platform version
VS2022 17.2.0 Preview 1.0
Description
After upgrading all my nugets to the latest versions, the following are new warnings.
Also attaching the MS Build log. Do you need anything else from me?
Could you please advise about the following, where it comes from etc?
Missing class androidx.window.extensions.WindowExtensions (referenced from: androidx.window.extensions.embedding.ActivityEmbeddingComponent
Build04032022.zip
Steps to Reproduce
N/A
Did you find any workaround?
The app deploys and runs just fine.
Relevant log output
No response