uno.extensions icon indicating copy to clipboard operation
uno.extensions copied to clipboard

Implicit dependency on Microsoft.Identity.Client.Extensions.Msal breaks Wasm builds

Open jeromelaban opened this issue 1 year ago • 0 comments

Current behavior

https://github.com/unoplatform/uno.extensions/commit/14979905a3a4c35a2f72a546d3471ffa32da6bb9 removed the Microsoft.Identity.Client.Extensions.Msal dependency from net8.0, but this dependency is still required to get Wasm apps to build.

This implicitly becomes a hidden dependendy, and while uno.sdk can be adjusted to work around that, apps not using uno.sdk will fail with this:

C:\Users\jela\.nuget\packages\uno.wasm.bootstrap\8.0.16\build\Uno.Wasm.Bootstrap.targets(213,3): [00:00:01.0838302] Unhandled exception. System.Exception: Could not resolve Microsoft.Identity.Client.Extensions.Msal

To fix this, we need a similar behavior to what's done with lottie, but when wasm is detected:

https://github.com/unoplatform/uno/blob/4533fe26120d4eeb7ce4198e08d5593c91d69f50/src/AddIns/Uno.UI.Lottie/buildTransitive/Uno.UI.Lottie.targets#L9-L29

jeromelaban avatar Jun 13 '24 13:06 jeromelaban