Microsoft.Maui.Controls.Maps crash when IsShowingUser = true in Release mode (iOS, NET 9 rc2) #25762
Labels
area-controls-map
Map / Maps
platform/iOS 🍎
s/triaged
Issue has been reviewed
t/bug
Something isn't working
Milestone
Description
I'm expercienced a crash in the map control in Release mode on real device only if IsShowingUser = true while zooming/pinching on the map.
Unhandled managed exception: Arg_InvalidCastException (System.InvalidCastException)
Tried both Microsoft.Maui.Controls.Maps version 9.0.0-rc.2.24503.2 and the latest ones 8.0.92 and 8.0.93 but all of them has the same problem. This used to work using .NET 8, at least on iOS 17.x.
Steps to Reproduce
Attached a simple project, apparently no special things to do other than set IsShowingUser = true to reproduce the error.
This on real device.
P.S. in the .csproj you have to adjust the CodesignKey.
TestMap.zip
Link to public reproduction project repository
No response
Version with bug
9.0.0-rc.2.24503.2
Is this a regression from previous behavior?
Yes, this used to work in .NET MAUI
Last version that worked well
Unknown/Other
Affected platforms
iOS
Affected platform versions
iOS 18, iOS 18.1 NET 9 rc2
Did you find any workaround?
Not really a workaround but just adding a Circle to the map and polling the position my self.
Relevant log output
The text was updated successfully, but these errors were encountered: