When i try to launch my application from Xcode to the device, i get this error:
error: failed to launch \'/Users/Luca/Library/Developer/Xcode/DerivedData/myapp-b
The only way I was able to fix this was to hard-boot my iPhone (hold down power and menu button until it powers off) and restart Xcode.