Skip to content

[Bug] MAUI templates crashing on iOS (Foundation.NSMutableData:AppendBytes) #61153

@PureWeen

Description

@PureWeen

Description

Application is failing to start

=================================================================
	Managed Stacktrace:
=================================================================
	  at <unknown> <0xffffffff>
	  at ObjCRuntime.Messaging:void_objc_msgSend_IntPtr_UIntPtr <0x0006e>
	  at Foundation.NSMutableData:AppendBytes <0x0004a>
	  at Foundation.NSData:FromStream <0x000dc>
	  at Microsoft.Maui.EmbeddedFontLoader:LoadFont <0x0006a>
	  at Microsoft.Maui.FontRegistrar:LoadEmbeddedFont <0x000a0>
	  at Microsoft.Maui.FontRegistrar:LoadNativeAppFont <0x0003a>
	  at Microsoft.Maui.FontRegistrar:GetFont <0x0011a>
	  at Microsoft.Maui.FontManager:CleanseFontName <0x00022>
	  at Microsoft.Maui.FontManager:CreateFont <0x0015e>
	  at System.Collections.Concurrent.ConcurrentDictionary`2:GetOrAdd <0x000e2>
	  at Microsoft.Maui.FontManager:GetFont <0x00074>
	  at Microsoft.Maui.FontManager:GetFont <0x00032>
	  at Microsoft.Maui.LabelExtensions:UpdateFont <0x0002a>
	  at Microsoft.Maui.LabelExtensions:UpdateFont <0x0001c>
	  at Microsoft.Maui.Handlers.LabelHandler:MapFont <0x0003e>
	  at Microsoft.Maui.Controls.Label:MapFont <0x0002e>
	  at <>c__DisplayClass5_0:<Add>b__0 <0x00048>
	  at Microsoft.Maui.PropertyMapper:UpdatePropertyCore <0x00036>
	  at Microsoft.Maui.PropertyMapper:UpdateProperties <0x0005e>

Steps to Reproduce

dotnet workload install maui `
   --from-rollback-file https://aka.ms/dotnet/maui/preview.10.json `
   --source https://aka.ms/dotnet6/nuget/index.json `
   --source https://api.nuget.org/v3/index.json
  • dotnet new maui
  • launch the iOS app

Expected Behavior

doesn't crash

Actual Behavior

crashes

Basic Information

  • Version with issue: main
  • Last known good version: p10

This is acting like an issue with the iOS workloads. If you change the version of MAUI to be p.10 but still use the p.11 iOS workloads the app still crashes.

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions