Bundle Identifier and push certificate… aps-environment entitlement error

前端 未结 19 2550
滥情空心
滥情空心 2020-11-29 17:38

I\'ve read Where does xcode take application's Identifier from? , XCode bundle identifier formatting from {PRODUCT_NAME} , and loads more but...

I\'m trying to g

19条回答
  •  囚心锁ツ
    2020-11-29 17:54

    I had this problem, the scenario was:

    I had setup an app id without push notifications support. I'm using Xcode 5.1 + iOS 7.1

    Later, edited the app id to add push notifications in development and production.

    Created the APNs certificates for both.

    When you test PN using your device attached to Xcode, everything works ok. The problem appears when you release the app to production, you keep getting:

    "Error Domain=NSCocoaErrorDomain Code=3000 "no valid 'aps-environment' entitlement string
     found for application" UserInfo=0x15b200 {NSLocalizedDescription=no valid     
    'apsenvironment' entitlement string found for application}" error.
    

    The solution that worked for me was:

    1. Delete provisioning profiles for development and distribution (Xcode and Developer portal).
    2. Delete your app ID (Developer portal).
    3. Create a new App ID with Push Notifications Support for Development and Production.
    4. Create new provisioning profiles using the NEW App ID.
    5. Install them on Xcode.
    6. Test on development and distribution release.

提交回复
热议问题