Xcode 11 live preview instantly crashes on real device

0

I am trying out SwiftUI with live preview. And everything went well while i was testing ui on simulator, but when i tried to use live preview on real device it instantly crashed.

I get error: Cannot preview in this file - Update failed

And in diagnostic:

PotentialCrashError: Update failed

[AppNAme].app may have crashed. Check ~/Library/Logs/DiagnosticReports for any crash logs from
your application.

And this weird looking logs:

Error Domain=com.apple.dt.UITestingAgent Code=-1 "failed to load library at path 
"/private/var/mobile/Containers/Data/Application/7F8714DD-B929-4D68-81F2-
5AF69FA9B002//tmp/74370CA4-397B-4477-9239-2DBC7CC4943D-ContentView.2.preview-thunk.dylib": 
Optional(dlopen(/private/var/mobile/Containers/Data/Application/7F8714DD-B929-4D68-81F2-
5AF69FA9B002/tmp/74370CA4-397B-4477-9239-2DBC7CC4943D-ContentView.2.preview-thunk.dylib, 
0x0002): code signature invalid (errno=1) sliceOffset=0x00000000, codeBlobOffset=0x00011550, 
codeBlobSize=0x00004A50 for '/private/var/mobile/Containers/Data/Application/7F8714DD-B929-4D68-
81F2-5AF69FA9B002/tmp/74370CA4-397B-4477-9239-2DBC7CC4943D-ContentView.2.preview-thunk.dylib')"
UserInfo={NSLocalizedDescription=failed to load library at path 
"/private/var/mobile/Containers/Data/Application/7F8714DD-B929-4D68-81F2-
5AF69FA9B002//tmp/74370CA4-397B-4477-9239-2DBC7CC4943D-ContentView.2.preview-thunk.dylib": 
Optional(dlopen(/private/var/mobile/Containers/Data/Application/7F8714DD-B929-4D68-81F2-
5AF69FA9B002/tmp/74370CA4-397B-4477-9239-2DBC7CC4943D-ContentView.2.preview-thunk.dylib, 
0x0002): code signature invalid (errno=1) sliceOffset=0x00000000, codeBlobOffset=0x00011550,
 codeBlobSize=0x00004A50 for '/private/var/mobile/Containers/Data/Application/7F8714DD-B929-
4D68-81F2-5AF69FA9B002/tmp/74370CA4-397B-4477-9239-2DBC7CC4943D-ContentView.2.preview-
thunk.dylib')}

ios
swift
xcode11
live-preview
asked on Stack Overflow Feb 22, 2020 by Egor Kolyshkin

0 Answers

Nobody has answered this question yet.


User contributions licensed under CC BY-SA 3.0