Why "add Push notification feature to your app id" warning even after push-notification showing enabled in App ID?
Solution 1
I restarted XCode and it was gone :-)
Solution 2
Close Xcode -> reopen -> clean -> build -> run.
Fixed the issue for me. Xcode 9.0.
Solution 3
Sadly I quit xcode then installed the .mobileprovision (double clicking it) then restarted xcode and the warning was gone...Followed the other answer here by SteMa
Solution 4
This happened to me. For some reason xCode signed me out. The fix: Tap Xcode (top bar) -> select Preferences -> select your Apple Id -> Sign-in. Hope this helps someone!
Solution 5
In my case it does not help restarting xcode again.
I just restart system and that problem was gone.
New iOS Dev
Updated on November 18, 2021Comments
-
New iOS Dev over 2 years
I am using Xcode8, swift 3, iOS 10
In Targets -> capabilities showing "add the Push notification feature to your app id".
I check my APP ID and it is showing pushnotfication enabled in both development and distribution.
With same APP IS and certificate I am getting notification in iOS9 but in iOS 10 i am getting error
Error Domain=NSCocoaErrorDomain Code=3000 "no valid 'aps-environment' entitlement string found for application" UserInfo={NSLocalizedDescription=no valid 'aps-environment' entitlement string found for application}
and also showing red mark (issue)
-
Whirlwind over 7 yearsLoL... And yeah sadly, this is the correct answer. Probably a Clean would work too.
-
luk2302 over 7 yearsIn what way is that an answer to the question?
-
sam k over 7 yearsQuitting Xcode and installing .mobileprovision, then restarting Xcode will solve the problem.
-
user18853 about 7 yearsI am singing 'sad but true' \m/
-
Raghav about 7 yearsI did clean>>build>>restarted XCode and it was gone.
-
Ionut over 6 yearsCan you please provide an example for what you did? From where would I regenerate my provisioning profiles and from where to re-dowload them and where to put them after download? I'm very new to xCode.
-
Alappin over 6 years@Ionut you have to regenerate the provisioning profile in the developer.apple.com/account/ios/profile/production of your account after you enable push for your app. You then re-download the profile and add it to Xcode in your app signing section.
-
Adrian Teh over 6 yearsThis is hilarious :)
-
Nick Sotiros about 6 yearsAfter spending several hours revoking and recreating provisioning profiles on developer.apple.com, this worked. FU xcode
-
Shyam over 5 yearsYup, for those of who restarted XCode and still didnt get it fixed, restarting the pc works.