I know this has been asked and answered multiple times but I\'m tearing my hair out as none of the proposed solutions appears to work.
+1 to banging my head against the wall for a day or two...
Also check this setting:
Build Settings -> Code Signing -> Provisioning Profile
After following the above steps, "Automatic" setting worked for me. ~kjm~