I have a SwiftUI application with a Core Data model. This model contains some entities, with properties. The canvas is working as expected, showing the preview.
But whenever I add a new entity, event without any property, the canvas fail to show the preview (event a basic view with only a text view in it). The error message is the following:
I tried to clean my cache, the derived data folder, reset the simulators, etc. When I click on Diagnostics, here is the message:Cannot preview in this file - The operation couldn't be completed. Transaction failed. Process failed to launch.
Any idea why I have that?Error Domain=FBProcessExit Code=4 "The process crashed." UserInfo={NSLocalizedFailureReason=The process crashed., BSErrorCodeDescription=crash, NSUnderlyingError=0x600002f29dd0 {Error Domain=signal Code=4 "SIGILL(4)" UserInfo={NSLocalizedFailureReason=SIGILL(4)}}}
RemoteHumanReadableError: The operation couldn’t be completed. Transaction failed. Process failed to launch. (process launch failed)
BSTransactionError (1):
==error-description: Process failed to launch.
==precipitating-error: Error Domain=FBProcessExit Code=4 "The process crashed." UserInfo={NSLocalizedFailureReason=The process crashed., BSErrorCodeDescription=crash, NSUnderlyingError=0x600002f29dd0 {Error Domain=signal Code=4 "SIGILL(4)" UserInfo={NSLocalizedFailureReason=SIGILL(4)}}}
==NSLocalizedFailureReason: Transaction failed. Process failed to launch. (process launch failed)
==transaction: <FBApplicationProcessLaunchTransaction: 0x60000186d960>
==error-reason: process launch failed
Thanks,
Axel
PS: I'm using Xcode 12 beta 6 (also tried on beta 5). I'm on macOS Big Sur (20A5364e).
Glad you were able to fix your issue, and I believe you reached the right conclusion that it was caused by a the currently installed version of the app having an old version of the data model, and you didn't have migration code to handle updating it to the current data model so it was crashing on launch. simctl has a convince for clearing out the preview sim's by using xcrun simctl --set previews delete all