Xcode 8.2 beta wrong path for Simulator

I'm trying to debug my app in the simulator so I click the 'Build and then run current Schema' button. I get the following error from XCode:

Cannot launch simulated executable: no file found at /Users/[myusername]/Library/Developer/Xcode/DerivedData/[myProjectName]-btwfgawblegvrqcojbqvgxppqqfl/Build/Products/Debug-iphoneos/[myAppName].app


I go look at the folders and XCode is putting the app in:

/Users/[myusername]/Library/Developer/Xcode/DerivedData/[myProjectName]-btwfgawblegvrqcojbqvgxppqqfl/Build/Products/Debug-iphonesimulator/[myAppName].app


I can't seem to find where it's determining to use the Debug-iphonesimulator folder and don't know how to change it to Debug-iphoneos.


Is there a build setting I'm missing or is it just a bug in xCode?


My lame workaround is to delete the app and the .dSYM files from the Debug-iphoneos folder, get the error message then copy the app and .dSYM files from the Debug-iphonesimulator folder and repeat.

Most times this issue is cleared by restarting the computer so Xcode can completly clear it's little head.


Before that, delete all versions of that app from the simulator, delete derived data, and in that project, use the 'Product' menu w/the option key pressed, then choose to 'clean build folder'.


Good luck.

Xcode 8.2 beta wrong path for Simulator
 
 
Q