the following code produces this crash for about 0.5% of the users :
guard let encodedData = try? jsonEncoder.encode(project) else {
throw AutoCapError.encodeVideoProject
}
Crashed: com.apple.root.background-qos 0 libswiftCore.dylib 0x20e468 StringObject.getSharedUTF8Start() + 8 1 libswiftCore.dylib 0x20e498 StringObject.sharedUTF8.getter + 24 2 Foundation 0x259698 specialized String.withUTF8<A>(:) + 1348 3 Foundation 0x25986c JSONWriter.serializeString(:) + 100 4 Foundation 0x44648 JSONWriter.serializeJSON(:depth:) + 92 5 Foundation 0x44d68 JSONWriter.serializeObject(:depth:) + 1344 6 Foundation 0x4474c JSONWriter.serializeJSON(:depth:) + 352 7 Foundation 0x44d68 JSONWriter.serializeObject(:depth:) + 1344 8 Foundation 0x460a8 JSONWriter.serializeArray(:depth:) + 892 9 Foundation 0x44718 JSONWriter.serializeJSON(:depth:) + 300 10 Foundation 0x44d68 JSONWriter.serializeObject(:depth:) + 1344 11 Foundation 0x460a8 JSONWriter.serializeArray(:depth:) + 892 12 Foundation 0x44718 JSONWriter.serializeJSON(:depth:) + 300 13 Foundation 0x44d68 JSONWriter.serializeObject(:depth:) + 1344 14 Foundation 0x4474c JSONWriter.serializeJSON(:depth:) + 352 15 Foundation 0x43ce8 JSONEncoder.encode<A>(:value:) + 608 16 Foundation 0x43a7c JSONEncoder.encode<A>(:) + 64 17 Foundation 0x43a34 dispatch thunk of JSONEncoder.encode<A>(_:) + 56
the crash started since the iOS 17 (worked before) the project Object is has many String fields and it mostly crashes on none english languages, Why isn't the try catches the crash? what might be causing it? fool crash report is attached