swiftUI preview does not open

I was studying swiftUI at SwiftUI Tutorials.

On the way, the preview of swiftUI is in a state where the preview does not open with the error "cannot preview in this file --Failed to install".

open the Diagnostics

FailedToInstallAppError: Failed to install "appname.app"
Could not install the preview host "appname.app" on iphone8

I get the error

I created a new project and tried it, but I get the same error.

Did the settings change?

I would like advice on how to deal with it.
The problem has been solved.
  1. Deleted the ”user name\Library\Developer\Xcode\ProductName...” folder.

  2. Launch the project file again.

swiftUI preview does not open
 
 
Q