ホーリーのプログラミング日記

ホーリーのプログラミング日記

エキセントリック・スーパーアプリクリエイター / アプリ総DL数 約180万 / 全然分からない 俺は雰囲気でアプリを作ってる / iOS : apple.co/3m3HxSm / Android : bit.ly/3ma0liZ

【解決済み】AppStoreConnectから"Missing Push Notification Entitlement"のメールをもらった話

 

Xcodeからアプリをアップロードしたら、AppStoreConnectからこんなメールをいただきました。

 

Missing Push Notification Entitlement - Your app appears to register with the Apple Push Notification service, but the app signature's entitlements do not include the "aps-environment" entitlement. If your app uses the Apple Push Notification service, make sure your App ID is enabled for Push Notification in the Provisioning Portal, and resubmit after signing your app with a Distribution provisioning profile that includes the "aps-environment" entitlement. Xcode 8 does not automatically copy the aps-environment entitlement from provisioning profiles at build time. This behavior is intentional. To use this entitlement, either enable Push Notifications in the project editor's Capabilities pane, or manually add the entitlement to your entitlements file. For more information, see https://developer.apple.com/library/content/documentation/NetworkingInternet/Conceptual/RemoteNotificationsPG/HandlingRemoteNotifications.html#//apple_ref/doc/uid/TP40008194-CH6-SW1.

 

Google翻訳にかけると、こんな感じ。

 

不足プッシュ通知資格 - あなたのアプリケーションはApple Push Notificationサービスに登録されているように見えますが、アプリ署名の資格には「aps-environment」資格が含まれていません。アプリがApple Push Notificationサービスを使用している場合は、Provisioning Portalでプッシュ通知が有効になっていることを確認し、「aps-environment」エンタイトルメントを含むDistributionプロビジョニングプロファイルでアプリに署名した後に再送信してください。 Xcode 8は、ビルド時にプロビジョニングプロファイルからaps-environment資格を自動的にコピーしません。この動作は意図的です。このエンタイトルメントを使用するには、プロジェクトエディタの機能ペインでプッシュ通知を有効にするか、エンタイトルメントファイルに手動でエンタイトルメントを追加します。詳細については、https://developer.apple.com/library/content/documentation/NetworkingInternet/Conceptual/RemoteNotificationsPG/HandlingRemoteNotifications.html#//apple_ref/doc/uid/TP40008194-CH6-SW1を参照してください。

 

ザックリ言えば、プッシュ通知使うなら、その設定してよねってことでしょう。多分w

 

こないだの位置情報みたいに、実際に使ってないのなら無視しても大丈夫そうなんですが、今回はプッシュ通知使ってるので、ちゃんと設定することにしました。

【解決済み】AppStoreConnectから"NSLocationWhenInUseUsageDescription"キーがないよってメールをもらった話 - ホーリーのプログラミング日記

 

f:id:gevvoihorry:20180915155030p:plain

 

XcodeのCapabilitiesを選んで。

 

f:id:gevvoihorry:20180915155124p:plain

 

Push NotificationをONにします。

 

どうもこれだけでOKだったっぽいです。アップロードしたら、今度は警告のメールがきませんでした。

 

しかしこういうメールをもらうと、一瞬ドキッとしますよね。アプリ申請って何でこんなに難しいんでしょうw