Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

FileNotFoundException when running on iOS with .NET 8 MAUI #136

Open
munkii opened this issue Nov 12, 2024 · 0 comments
Open

FileNotFoundException when running on iOS with .NET 8 MAUI #136

munkii opened this issue Nov 12, 2024 · 0 comments

Comments

@munkii
Copy link

munkii commented Nov 12, 2024

Using .NET8 MAUI version 8.0.91 and SimpleAuth 1.0.56-beta

After adding SimpleAuth to the MAUI project template I get the following error trying to instaniate FitBitAp,i when deploying to iOS. There is no issue when deploying to Android.

System.IO.FileNotFoundException: 'Could not load file or assembly 'Xamarin.iOS, Version=0.0.0.0, Culture=neutral, PublicKeyToken=84e04ff9cfb79065' or one of its dependencies.'

Here is a link to a repro
https://github.com/munkii/SimpleAuthFileNotFoundRepro

Here is the call stack

0x0 in SimpleAuth.Providers.FitBitApi..ctor at C:\Projects\SimpleAuth\src\SimpleAuth\Providers\Google.cs:106,4 C#

0x1E in SimpleAuthFileNotFoundRepro.ViewModel.MainViewModel..ctor at C:\Users\longp\source\repos\SimpleAuthFileNotFoundRepro\SimpleAuthFileNotFoundRepro\ViewModel\MainViewModel.cs:19,13 C#
0x1B in System.Reflection.RuntimeConstructorInfo.InternalInvoke C#
0xF in System.Reflection.MethodBaseInvoker.InterpretedInvoke_Constructor C#
0x2D in System.Reflection.MethodBaseInvoker.InvokeWithNoArgs C#
0xB4 in System.RuntimeType.CreateInstanceMono C#
0x1F in System.RuntimeType.CreateInstanceDefaultCtor C#
0x30 in System.Activator.CreateInstance C#
0x3 in System.Activator.CreateInstance C#
0x2 in System.Activator.CreateInstance C#
0x2B2 in Microsoft.Maui.Controls.Xaml.CreateValuesVisitor.Visit at //src/Controls/src/Xaml/CreateValuesVisitor.cs:102,46 C#
0x93 in Microsoft.Maui.Controls.Xaml.ElementNode.Accept at /
/src/Controls/src/Xaml/XamlNode.cs:189,37 C#
0x48 in Microsoft.Maui.Controls.Xaml.RootNode.Accept at //src/Controls/src/Xaml/XamlNode.cs:240,33 C#
0x6C in Microsoft.Maui.Controls.Xaml.XamlLoader.Visit at /
/src/Controls/src/Xaml/XamlLoader.cs:208,67 C#
0xE4 in Microsoft.Maui.Controls.Xaml.XamlLoader.Load at //src/Controls/src/Xaml/XamlLoader.cs:78,30 C#
0x4 in Microsoft.Maui.Controls.Xaml.XamlLoader.Load at /
/src/Controls/src/Xaml/XamlLoader.cs:53,125 C#
0x2C in Microsoft.Maui.Controls.Xaml.XamlLoader.Load at //src/Controls/src/Xaml/XamlLoader.cs:49,42 C#
0x7 in Microsoft.Maui.Controls.Xaml.Extensions.LoadFromXaml<SimpleAuthFileNotFoundRepro.MainPage> at /
/src/Controls/src/Xaml/ViewExtensions.cs:37,39 C#
0xC in SimpleAuthFileNotFoundRepro.MainPage.InitializeComponent at C:\Users\longp\source\repos\SimpleAuthFileNotFoundRepro\SimpleAuthFileNotFoundRepro\obj\Debug\net8.0-ios\ios-arm64\Microsoft.Maui.Controls.SourceGen\Microsoft.Maui.Controls.SourceGen.CodeBehindGenerator\MainPage.xaml.sg.cs:26,4 C#
0x10 in SimpleAuthFileNotFoundRepro.MainPage..ctor at C:\Users\longp\source\repos\SimpleAuthFileNotFoundRepro\SimpleAuthFileNotFoundRepro\MainPage.xaml.cs:9,13 C#
0x1B in System.Reflection.RuntimeConstructorInfo.InternalInvoke C#
0xF in System.Reflection.MethodBaseInvoker.InterpretedInvoke_Constructor C#
0x2D in System.Reflection.MethodBaseInvoker.InvokeWithNoArgs C#
0xB4 in System.RuntimeType.CreateInstanceMono C#
0x1F in System.RuntimeType.CreateInstanceDefaultCtor C#
0x30 in System.Activator.CreateInstance C#
0x3 in System.Activator.CreateInstance C#
0x2 in System.Activator.CreateInstance C#
0x48 in Microsoft.Maui.Controls.ShellContent. at //src/Controls/src/Core/SwipeView/SwipeView.cs:421,5 C#
0x27 in Microsoft.Maui.Controls.ElementTemplate.CreateContent at /
/src/Controls/src/Core/Element/Element.cs:226,4 C#
0x8 in Microsoft.Maui.Controls.Internals.DataTemplateExtensions.CreateContent at //src/Controls/src/Core/Internals/ImageParser.cs:287,37 C#
0x77 in Microsoft.Maui.Controls.ShellContent.Microsoft.Maui.Controls.IShellContentController.GetOrCreateContent at /
/src/Controls/src/Core/Shell/ShellElementCollection.cs:105,31 C#
0x21 in Microsoft.Maui.Controls.Platform.Compatibility.ShellSectionRootRenderer.LoadRenderers at //src/Controls/src/Core/Compatibility/Handlers/Shell/Android/ShellItemRenderer.cs:442,36 C#
0xD3 in Microsoft.Maui.Controls.Platform.Compatibility.ShellSectionRootRenderer.ViewDidLoad at /
/src/Controls/src/Core/Compatibility/Handlers/Shell/Android/ShellItemRenderer.cs:331,16 C#
0x38 in UIKit.UIApplication.xamarin_UIApplicationMain C#
0xF in UIKit.UIApplication.UIApplicationMain at /Users/builder/azdo/_work/1/s/xamarin-macios/src/UIKit/UIApplication.cs:61,5 C#
0x4A in UIKit.UIApplication.Main at /Users/builder/azdo/_work/1/s/xamarin-macios/src/UIKit/UIApplication.cs:96,4 C#
0xD in SimpleAuthFileNotFoundRepro.Program.Main at C:\Users\longp\source\repos\SimpleAuthFileNotFoundRepro\SimpleAuthFileNotFoundRepro\Platforms\iOS\Program.cs:13,13 C#

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

No branches or pull requests

1 participant