I just cracked open an older project to apply a bug fix.
After 2 minutes of fixing the, bug I go to build it to my device, and I get this error \"A valid provisioni
I have a solution as well. This happened to me last night with the exact same error. I had a program that was previously compiling and now that I am adding an update to my app, the same error was displayed. The problem is that I forgot to change my provisioning profile back to Developer. (You set it to Distribution when uploading your app to the App Store).
Here are the settings for Xcode 4.6.
In your app click Targets -> YourAppName -> Code Signing Identy.
Change iPhone Distribution to iPhone Developer.
Your app will now compile.