themronion/Maui.GoogleMaps

[iOS] None of the sample pages working

johnclarete opened this issue · 5 comments

VERSIONS

  • Maui.GoogleMaps - x.x.x
  • .NET SDK - 8

IDE

  • Rider
  • Visual Studio
  • Visual Studio for Mac

PLATFORMS

  • Android
  • iOS

ACTUAL BEHAVIOR

When testing out the sample repository I can't seem to get any of the sample pages to work but I was specifically looking to view the Binding Pin page.

ACTUAL SCREENSHOTS/STACKTRACE

An error occurred: 'Could not create an native instance of the type 'Google.Maps.MapView': the native class hasn't been loaded.
It is possible to ignore this condition by setting ObjCRuntime.Class.ThrowOnInitFailure to false.'. Callstack: ' at Foundation.NSObject.InitializeObject(Boolean alloced) in /Users/builder/azdo/_work/1/s/xamarin-macios/src/Foundation/NSObject2.cs:line 363
at Foundation.NSObject..ctor(NSObjectFlag x) in /Users/builder/azdo/_work/1/s/xamarin-macios/src/Foundation/NSObject2.cs:line 214
at UIKit.UIResponder..ctor(NSObjectFlag t) in /Users/builder/azdo/_work/1/s/xamarin-macios/src/build/dotnet/ios/generated-sources/UIKit/UIResponder.g.cs:line 75
at UIKit.UIView..ctor(NSObjectFlag t) in /Users/builder/azdo/_work/1/s/xamarin-macios/src/build/dotnet/ios/generated-sources/UIKit/UIView.g.cs:line 89
at Google.Maps.MapView..ctor(CGRect frame)
at Maui.GoogleMaps.Handlers.MapHandler.CreatePlatformView() in C:\Users\johnc\source\repos\Maui.GoogleMaps\lib\Maui.GoogleMaps\Platforms\iOS\MapHandler.cs:line 32
at Microsoft.Maui.Handlers.ViewHandler2[[Maui.GoogleMaps.Map, Maui.GoogleMaps, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null],[Google.Maps.MapView, Google.Maps, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null]].OnCreatePlatformView() at Microsoft.Maui.Handlers.ViewHandler.OnCreatePlatformElement() at Microsoft.Maui.Handlers.ElementHandler.CreatePlatformElement() at Microsoft.Maui.Handlers.ElementHandler.SetVirtualView(IElement view) at Microsoft.Maui.Handlers.ViewHandler2[[Maui.GoogleMaps.Map, Maui.GoogleMaps, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null],[Google.Maps.MapView, Google.Maps, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null]].SetVirtualView(IView view)
at Microsoft.Maui.Handlers.ViewHandler2[[Maui.GoogleMaps.Map, Maui.GoogleMaps, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null],[Google.Maps.MapView, Google.Maps, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null]].SetVirtualView(IElement view) at Microsoft.Maui.Controls.Element.SetHandler(IElementHandler newHandler) at Microsoft.Maui.Controls.Element.set_Handler(IElementHandler value) at Microsoft.Maui.Controls.VisualElement.Microsoft.Maui.IElement.set_Handler(IElementHandler value) at Microsoft.Maui.Platform.ElementExtensions.ToHandler(IElement view, IMauiContext context) at Microsoft.Maui.Platform.ElementExtensions.ToPlatform(IElement view, IMauiContext context) at Microsoft.Maui.Handlers.LayoutHandler.SetVirtualView(IView view) at Microsoft.Maui.Handlers.ViewHandler2[[Microsoft.Maui.ILayout, Microsoft.Maui, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null],[Microsoft.Maui.Platform.LayoutView, Microsoft.Maui, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null]].SetVirtualView(IElement view)
at Microsoft.Maui.Controls.Element.SetHandler(IElementHandler newHandler)
at Microsoft.Maui.Controls.Element.set_Handler(IElementHandler value)
at Microsoft.Maui.Controls.VisualElement.Microsoft.Maui.IElement.set_Handler(IElementHandler value)
at Microsoft.Maui.Platform.ElementExtensions.ToHandler(IElement view, IMauiContext context)
at Microsoft.Maui.Platform.ElementExtensions.ToPlatform(IElement view, IMauiContext context)
at Microsoft.Maui.Handlers.ContentViewHandler.UpdateContent(IContentViewHandler handler)
at Microsoft.Maui.Handlers.ContentViewHandler.MapContent(IContentViewHandler handler, IContentView page)
at Microsoft.Maui.PropertyMapper2.<>c__DisplayClass5_0[[Microsoft.Maui.IContentView, Microsoft.Maui, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null],[Microsoft.Maui.Handlers.IContentViewHandler, Microsoft.Maui, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null]].<Add>b__0(IElementHandler h, IElement v) at Microsoft.Maui.PropertyMapper.UpdatePropertyCore(String key, IElementHandler viewHandler, IElement virtualView) at Microsoft.Maui.PropertyMapper.UpdateProperties(IElementHandler viewHandler, IElement virtualView) at Microsoft.Maui.Handlers.ElementHandler.SetVirtualView(IElement view) at Microsoft.Maui.Handlers.ViewHandler2[[Microsoft.Maui.IContentView, Microsoft.Maui, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null],[Microsoft.Maui.Platform.ContentView, Microsoft.Maui, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null]].SetVirtualView(IView view)

EXPECTED BEHAVIOR

Show the page of the button clicked

HOW TO REPRODUCE

  1. Clone current branch
  2. Run sample for ios
  3. Click on one of the buttons

Are u using hot restart on Windows? If yes, please don't, use a normal mac.

Are u using hot restart on Windows? If yes, please don't, use a normal mac.

Thank you, that was it.

Are u using hot restart on Windows? If yes, please don't, use a normal mac.

Is there a way to use it with hot restart on windows? What would be required?

No

What is the reason? Maybe something could be retrieved from mac to allow future development on windows?