20210910のiOSに関する記事は5件です。

fastlane match で既存の秘密鍵、証明書、プロビジョニングを取り込む

想定ケース 諸事情により Apple Developer Portal へのアクセス権限がない 手元に秘密鍵、証明書、プロビジョニングのファイルはある、もしくは Keychain に取り込み済み ファイルで直接やりとりするのではなく、 fastlane match で管理したい 作業手順 前提 fastlane 2.193.1 fastlane match 導入済みで、Storage の整備や Passphrase についても設定済み 秘密鍵、証明書については有効なものを Keychain に取り込み済み プロビジョニングについては有効なものがファイルとして手元にある 秘密鍵、証明書、プロビジョニングの用意 秘密鍵と証明書を Keychain からファイルに書き出します。 この際、開発者間でやりとりする場合のように、 Keychain 上で秘密鍵と証明書を2つ選択して1つの p12 ファイルとして書き出すのではなく、秘密鍵と証明書それぞれ1つずつ選択した状態でファイルに書き出していきます。 ファイルの拡張子については、以下のように選択。 対象 拡張子形式 秘密鍵 .p12 証明書 .cer 秘密鍵の書き出し時にはパスワードを設定しないようにします。 書き出し時のファイル名については、 fastlane match の Storage 内でもそのまま利用されるため、気にする場合は team id を利用してください。 同様に、プロビジョニングプロファイルのファイルについても、必要あれば app identifier を利用したファイル名に変更しておきます。 match import で Storage に取り込み $ fastlane match import --skip_certificate_matching true で、 import 作業を開始します。 --skip_certificate_matching true については、 証明書の有効性チェックやプロビジョニングの紐付けの確認のための Apple Developer Portalへのアクセスをスキップする( Apple Developer Portal にログインしない)ためのオプションとなっています。 $ fastlane match import --skip_certificate_matching true [✔] ? [09:41:00]: Successfully loaded '${path to Matchfile}' ? +--------------+------------------------------------------+ | Detected Values from './fastlane/Matchfile' | +--------------+------------------------------------------+ | git_url | ${fastlane match storage repository url} | | storage_mode | git | | type | appstore | +--------------+------------------------------------------+ [09:41:00]: Certificate (.cer) path: [09:41:00]: Private key (.p12) path: [09:41:00]: Provisioning profile (.mobileprovision or .provisionprofile) path or leave empty to skip this file: import 作業を開始すると、 Matchfile の読み取りが行われます。 Matchfile に未記載 or 上書きしたい設定については、 fastlane match import コマンド実行時のオプション指定も可能です。 この際、 type について意図したものが設定されていることを確認してください。 (主な利用ケースでは、 Distribution 用途で adhoc や appstore が多いかと思います。) 未設定の場合はデフォルト値の develop が利用されてしまいます。 その後 証明書( Certificate ) 秘密鍵( Private key ) プロビジョニング( Provisioning profile) の順で、ファイルのパスを聞かれるため、用意したファイルのフルパスを入力します。 問題なければ作業はこれで完了です。 参照する場合 Apple Developer Portal へのアクセス権限がない前提なので、 fastlane match で参照する際には、 --readonly true とします。 参考 irb を利用する方法もあります。
  • このエントリーをはてなブックマークに追加
  • Qiitaで続きを読む

fastlaneのdeliverからAppStoreのメタデータ送信する際の留意点

概要 2021/08現在における fastlane deliver を使った AppStore へのメタデータ送信について、ドキュメントが少なかったので留意点を記しておきます。 前準備 ■ AppStre API Key 2021/08現在では deliver からメタデータをCI経由で送る場合 AppStore API Key が必要です。 これがないと 2FA をクリアできないので、、 ローカルで実行するだけであれば、fastlane で利用できる通常のログイン機構で大丈夫です。 その場合、コマンドの途中で 2FA のパスワードを求められることになります。 ちなみに.envなどを利用して環境変数に必要keyを格納し、下記のようにAPIKeyを取得できるような fastlane private action を Fastfile に作っておくと便利です。 #### App Store API への認証Key生成 desc "App Store Connect API Key" # private_lane :app_store_connect_key do lane :app_store_connect_key do api_key = app_store_connect_api_key( key_id: ENV["APP_STORE_API_KEY_ID"], issuer_id: ENV["APP_STORE_API_ISSUE_ID"], key_content: ENV["APP_STORE_API_KEY_CONTENT"], duration: 1200, in_house: false ) end #### Deliverによるメタ情報&app送信 desc "Upload with Deliver" lane :deliver_app do |options| deliver( api_key: app_store_connect_key, 〜 割愛 〜 ) end AppStoreAPIに関するドキュメント ■ AppStore に送信するメタデータ AppStoreに送信するメタデータはAppStoreConnectのGUIに沿って設定したものをダウンロードすると良いです。 メタデータ用のファイル群だけでは何が何だかわかりずらく、一つ一つゼロから構築するのは大変なので。 ダウンロードはAppStoreへのログイン機構を利用したアクションの実行が必要です。 deliver の download_metadata 関数は api_key に対応していないので。。。 したがって Appfile などにログインに必要な項目を記載して実行してください。 下記のコマンドを実行すると 2FA を介してメタデータのダウンロードが行えます。 fastlane deliver download_metadata 以下を参考に更新があれば行ってみてください。 ■ AppStore に送信するスクリーンショット 下記にまとめているので参照してみてください。 ■ レーティングに関するメタデータ deliver でのメタデータ管理を行うのであれば、レーティングに関してもデータ送信できるようにしておいた方が良いです。 この辺の変更もGithubなどでバージョン管理できると、後続の関係者に意図が伝わると思います。 レーティング情報については fastlane 経由のダウンロード方法がわからなかったので、わかり次第追記したいと思います。 直接APIから取得する方法は こちら。 差し当たり、下記の json を用意して、プロダクトにあった設定値にしてください。 { "alcoholTobaccoOrDrugUseOrReferences": "NONE", "contests": "NONE", "gamblingSimulated": "NONE", "horrorOrFearThemes": "NONE", "matureOrSuggestiveThemes": "NONE", "medicalOrTreatmentInformation": "NONE", "profanityOrCrudeHumor": "NONE", "sexualContentGraphicAndNudity": "NONE", "sexualContentOrNudity": "NONE", "violenceCartoonOrFantasy": "NONE", "violenceRealisticProlongedGraphicOrSadistic": "NONE", "violenceRealistic": "NONE", "gambling": false, "seventeenPlus": false, "unrestrictedWebAccess": false } 以前はこちらのプルリク差分のように大文字での指定になっていましたが、指定が新しくなっているので注意してください。 レーティングのKeyValueドキュメント deliverからの送信 さてでは実際に deliver を利用してデータ送信する際のパラメータ設定についてです。 下記に基本的なものを羅列しておきました。 fastlane のドキュメントサイトにデフォルト値が記載されているので、改めて指定不要なものは削除してください。 注意書きですが、バイナリの送信を行う場合、当然ですが前もって fastlane の gym などを利用したアプリ生成が必要です。 また生成されたアプリバージョンがすでに AppStore に存在する場合エラーになるので注意してください。 deliver( api_key: app_store_connect_key, # <- 前述で説明した api_key を設定 submit_for_review: true, # <- バイナリ送信時にレビューに送信するか否か skip_binary_upload: true, # <- 生成されたバイナリをアップロードするか否か force: true, # <- おそらくですが送信時に生成されるHTMLレポートの検証をスキップするか否か。基本trueで良いようです reject_if_possible: true, # <- 申請中であれば取り消して上書きするかどうか metadata_path: "fastlane/metadata", # <- metadata のフォルダ指定 skip_screenshots: false, # <- スクショのアップをスキップするかどうか screenshots_path: "fastlane/screenshots", # <- スクショのフォルダ指定 overwrite_screenshots: true, # <- スクショを上書きするか否か automatic_release: true, # <- 申請通過時の自動リリース設定 app_rating_config_path: "fastlane/app_rating_config.json", # <- レーティングのjson指定 run_precheck_before_submit: false, # <- 送信前の検証。api_keyを利用するとこけるので false submission_information: { add_id_info_uses_idfa: false, # <- 広告ID情報-idfaを使用するか否か add_id_info_serves_ads: false, # <- 広告ID情報-広告を配信するか否か add_id_info_tracks_install: false, # <- 広告ID情報-インストールの追跡を行なっているかどうか add_id_info_tracks_action: false, # <- 広告ID情報-アクションの追跡を行なっているかどうか export_compliance_encryption_updated: false # <- 暗号化について更新があるかどうか } ) deliver公式ドキュメント   【補足】プライバシー詳細情報に関するメタデータについて 現状 deliver を利用してプライバシー詳細情報に関する設定値をアップロードすることはできませんが、バージョン管理の観点からメタデータによる fastlane 経由のアップロードを行うのも良いかと思います。 以下の記事を参照してみてください。       以上です。
  • このエントリーをはてなブックマークに追加
  • Qiitaで続きを読む

[Flutter][iOS]permission_handlerで不要な権限を削除

アプリをApp Store Connectに送信した際に(CI/CDで自動配布した際に)警告メールが届き、testflightでアプリをまくことができなかった 原因:どうやらAppleの静的解析ツールに引っかかっているらしい アプリのOS権限管理をpermission_handler 8.1.4+2にした後、ビルドしたバイナリをApp Store Connectに送信したら以下のようなめっちゃ長いメールが届いた。そんな場合の対処法をメモ 結論として、iOSのセットアップとして公式に記述されている方法と少し違った?ので注意が必要。 メール App Store Connect Dear Developer, We identified one or more issues with a recent delivery for your app, "hoge-app" 1.0.0. Please correct the following issues, then upload again. ITMS-90683: Missing Purpose String in Info.plist - Your app's code references one or more APIs that access sensitive user data. The app's Info.plist file should contain a NSContactsUsageDescription key with a user-facing purpose string explaining clearly and completely why your app needs the data. Starting Spring 2019, all apps submitted to the App Store that access user data are required to include a purpose string. If you're using external libraries or SDKs, they may reference APIs that require a purpose string. While your app might not use these APIs, a purpose string is still required. You can contact the developer of the library or SDK and request they release a version of their code that doesn't contain the APIs. Learn more (https://developer.apple.com/documentation/uikit/core_app/protecting_the_user_s_privacy). ITMS-90683: Missing Purpose String in Info.plist - Your app's code references one or more APIs that access sensitive user data. The app's Info.plist file should contain a NSCalendarsUsageDescription key with a user-facing purpose string explaining clearly and completely why your app needs the data. Starting Spring 2019, all apps submitted to the App Store that access user data are required to include a purpose string. If you're using external libraries or SDKs, they may reference APIs that require a purpose string. While your app might not use these APIs, a purpose string is still required. You can contact the developer of the library or SDK and request they release a version of their code that doesn't contain the APIs. Learn more (https://developer.apple.com/documentation/uikit/core_app/protecting_the_user_s_privacy). ITMS-90683: Missing Purpose String in Info.plist - Your app's code references one or more APIs that access sensitive user data. The app's Info.plist file should contain a NSAppleMusicUsageDescription key with a user-facing purpose string explaining clearly and completely why your app needs the data. Starting Spring 2019, all apps submitted to the App Store that access user data are required to include a purpose string. If you're using external libraries or SDKs, they may reference APIs that require a purpose string. While your app might not use these APIs, a purpose string is still required. You can contact the developer of the library or SDK and request they release a version of their code that doesn't contain the APIs. Learn more (https://developer.apple.com/documentation/uikit/core_app/protecting_the_user_s_privacy). ITMS-90683: Missing Purpose String in Info.plist - Your app's code references one or more APIs that access sensitive user data. The app's Info.plist file should contain a NSMotionUsageDescription key with a user-facing purpose string explaining clearly and completely why your app needs the data. Starting Spring 2019, all apps submitted to the App Store that access user data are required to include a purpose string. If you're using external libraries or SDKs, they may reference APIs that require a purpose string. While your app might not use these APIs, a purpose string is still required. You can contact the developer of the library or SDK and request they release a version of their code that doesn't contain the APIs. Learn more (https://developer.apple.com/documentation/uikit/core_app/protecting_the_user_s_privacy). ITMS-90683: Missing Purpose String in Info.plist - Your app's code references one or more APIs that access sensitive user data. The app's Info.plist file should contain a NSSpeechRecognitionUsageDescription key with a user-facing purpose string explaining clearly and completely why your app needs the data. Starting Spring 2019, all apps submitted to the App Store that access user data are required to include a purpose string. If you're using external libraries or SDKs, they may reference APIs that require a purpose string. While your app might not use these APIs, a purpose string is still required. You can contact the developer of the library or SDK and request they release a version of their code that doesn't contain the APIs. Learn more (https://developer.apple.com/documentation/uikit/core_app/protecting_the_user_s_privacy). Though you are not required to fix the following issues, we wanted to make you aware of them: ITMS-90683: Missing Purpose String in Info.plist - Your app's code references one or more APIs that access sensitive user data. The app's Info.plist file should contain a NSLocationWhenInUseUsageDescription key with a user-facing purpose string explaining clearly and completely why your app needs the data. Starting Spring 2019, all apps submitted to the App Store that access user data are required to include a purpose string. If you're using external libraries or SDKs, they may reference APIs that require a purpose string. While your app might not use these APIs, a purpose string is still required. You can contact the developer of the library or SDK and request they release a version of their code that doesn't contain the APIs. Learn more (https://developer.apple.com/documentation/uikit/core_app/protecting_the_user_s_privacy). Best regards, The App Store Team ...どうやら「アプリはたくさん権限をリクエストしているのに、Info.plistファイルに必要なキーが含まれていないですよ」という注意のよう。 しかし、これはpermission_handlerがデフォルトですべての権限のリクエストをしてしまっているせいなので、使う権限と使わない権限を明記してあげれば良し。 解決方法 ios/podfile post_install do |installer| installer.pods_project.targets.each do |target| flutter_additional_ios_build_settings(target) end end podfileの↑の部分に追記して以下のように変更! ios/podfile post_install do |installer| installer.pods_project.targets.each do |target| flutter_additional_ios_build_settings(target) target.build_configurations.each do |config| config.build_settings['GCC_PREPROCESSOR_DEFINITIONS'] ||= [ '$(inherited)', ## dart: PermissionGroup.calendar 'PERMISSION_EVENTS=0', ## dart: PermissionGroup.reminders 'PERMISSION_REMINDERS=0', ## dart: PermissionGroup.contacts 'PERMISSION_CONTACTS=0', ## dart: PermissionGroup.camera 'PERMISSION_CAMERA=1', ## dart: PermissionGroup.microphone 'PERMISSION_MICROPHONE=0', ## dart: PermissionGroup.speech 'PERMISSION_SPEECH_RECOGNIZER=0', ## dart: PermissionGroup.photos 'PERMISSION_PHOTOS=1', ## dart: [PermissionGroup.location, PermissionGroup.locationAlways, PermissionGroup.locationWhenInUse] 'PERMISSION_LOCATION=0', ## dart: PermissionGroup.notification 'PERMISSION_NOTIFICATIONS=0', ## dart: PermissionGroup.mediaLibrary 'PERMISSION_MEDIA_LIBRARY=0', ## dart: PermissionGroup.sensors 'PERMISSION_SENSORS=0', ## dart: PermissionGroup.bluetooth 'PERMISSION_BLUETOOTH=0', ## dart: PermissionGroup.appTrackingTransparency 'PERMISSION_APP_TRACKING_TRANSPARENCY=0', ## dart: PermissionGroup.criticalAlerts 'PERMISSION_CRITICAL_ALERTS=0' ] end end end 公式だと使う権限の'#'を消せばいいみたいに書いてあるが、使わない権限も記述する必要がある模様。 0→使わない権限 1→使う権限 機能追加などで権限が必要となった場合にはinfo.plistだけではなく、podfileも0を1に変更する。 参考 公式:https://pub.dev/packages/permission_handler
  • このエントリーをはてなブックマークに追加
  • Qiitaで続きを読む

[Flutter][iOS] permission_handler 不要な権限を削除

アプリをApp Store Connectに送信した際に(CI/CDで自動配布した際に)警告メールが届き、testflightでアプリをまくことができなかった 原因:どうやらAppleの静的解析ツールに引っかかっているらしい アプリのOS権限管理をpermission_handler 8.1.4+2にした後、ビルドしたバイナリをApp Store Connectに送信したら以下のようなめっちゃ長いメールが届いた。そんな場合の対処法をメモ 結論として、iOSのセットアップとして公式に記述されている方法と少し違った?ので注意が必要。 App Store Connectから来たメール App Store Connect Dear Developer, We identified one or more issues with a recent delivery for your app, "hoge-app" 1.0.0. Please correct the following issues, then upload again. ITMS-90683: Missing Purpose String in Info.plist - Your app's code references one or more APIs that access sensitive user data. The app's Info.plist file should contain a NSContactsUsageDescription key with a user-facing purpose string explaining clearly and completely why your app needs the data. Starting Spring 2019, all apps submitted to the App Store that access user data are required to include a purpose string. If you're using external libraries or SDKs, they may reference APIs that require a purpose string. While your app might not use these APIs, a purpose string is still required. You can contact the developer of the library or SDK and request they release a version of their code that doesn't contain the APIs. Learn more (https://developer.apple.com/documentation/uikit/core_app/protecting_the_user_s_privacy). ITMS-90683: Missing Purpose String in Info.plist - Your app's code references one or more APIs that access sensitive user data. The app's Info.plist file should contain a NSCalendarsUsageDescription key with a user-facing purpose string explaining clearly and completely why your app needs the data. Starting Spring 2019, all apps submitted to the App Store that access user data are required to include a purpose string. If you're using external libraries or SDKs, they may reference APIs that require a purpose string. While your app might not use these APIs, a purpose string is still required. You can contact the developer of the library or SDK and request they release a version of their code that doesn't contain the APIs. Learn more (https://developer.apple.com/documentation/uikit/core_app/protecting_the_user_s_privacy). ITMS-90683: Missing Purpose String in Info.plist - Your app's code references one or more APIs that access sensitive user data. The app's Info.plist file should contain a NSAppleMusicUsageDescription key with a user-facing purpose string explaining clearly and completely why your app needs the data. Starting Spring 2019, all apps submitted to the App Store that access user data are required to include a purpose string. If you're using external libraries or SDKs, they may reference APIs that require a purpose string. While your app might not use these APIs, a purpose string is still required. You can contact the developer of the library or SDK and request they release a version of their code that doesn't contain the APIs. Learn more (https://developer.apple.com/documentation/uikit/core_app/protecting_the_user_s_privacy). ITMS-90683: Missing Purpose String in Info.plist - Your app's code references one or more APIs that access sensitive user data. The app's Info.plist file should contain a NSMotionUsageDescription key with a user-facing purpose string explaining clearly and completely why your app needs the data. Starting Spring 2019, all apps submitted to the App Store that access user data are required to include a purpose string. If you're using external libraries or SDKs, they may reference APIs that require a purpose string. While your app might not use these APIs, a purpose string is still required. You can contact the developer of the library or SDK and request they release a version of their code that doesn't contain the APIs. Learn more (https://developer.apple.com/documentation/uikit/core_app/protecting_the_user_s_privacy). ITMS-90683: Missing Purpose String in Info.plist - Your app's code references one or more APIs that access sensitive user data. The app's Info.plist file should contain a NSSpeechRecognitionUsageDescription key with a user-facing purpose string explaining clearly and completely why your app needs the data. Starting Spring 2019, all apps submitted to the App Store that access user data are required to include a purpose string. If you're using external libraries or SDKs, they may reference APIs that require a purpose string. While your app might not use these APIs, a purpose string is still required. You can contact the developer of the library or SDK and request they release a version of their code that doesn't contain the APIs. Learn more (https://developer.apple.com/documentation/uikit/core_app/protecting_the_user_s_privacy). Though you are not required to fix the following issues, we wanted to make you aware of them: ITMS-90683: Missing Purpose String in Info.plist - Your app's code references one or more APIs that access sensitive user data. The app's Info.plist file should contain a NSLocationWhenInUseUsageDescription key with a user-facing purpose string explaining clearly and completely why your app needs the data. Starting Spring 2019, all apps submitted to the App Store that access user data are required to include a purpose string. If you're using external libraries or SDKs, they may reference APIs that require a purpose string. While your app might not use these APIs, a purpose string is still required. You can contact the developer of the library or SDK and request they release a version of their code that doesn't contain the APIs. Learn more (https://developer.apple.com/documentation/uikit/core_app/protecting_the_user_s_privacy). Best regards, The App Store Team ...どうやら「アプリはたくさん権限をリクエストしているのに、Info.plistファイルに必要なキーが含まれていないですよ」という注意のよう。 しかし、これはpermission_handlerがデフォルトですべての権限のリクエストをしてしまっているせいなので、使う権限と使わない権限を明記してあげれば良し。 解決方法 ios/podfile post_install do |installer| installer.pods_project.targets.each do |target| flutter_additional_ios_build_settings(target) end end podfileの↑の部分に追記して以下のように変更! ios/podfile post_install do |installer| installer.pods_project.targets.each do |target| flutter_additional_ios_build_settings(target) target.build_configurations.each do |config| config.build_settings['GCC_PREPROCESSOR_DEFINITIONS'] ||= [ '$(inherited)', ## dart: PermissionGroup.calendar 'PERMISSION_EVENTS=0', ## dart: PermissionGroup.reminders 'PERMISSION_REMINDERS=0', ## dart: PermissionGroup.contacts 'PERMISSION_CONTACTS=0', ## dart: PermissionGroup.camera 'PERMISSION_CAMERA=1', ## dart: PermissionGroup.microphone 'PERMISSION_MICROPHONE=0', ## dart: PermissionGroup.speech 'PERMISSION_SPEECH_RECOGNIZER=0', ## dart: PermissionGroup.photos 'PERMISSION_PHOTOS=1', ## dart: [PermissionGroup.location, PermissionGroup.locationAlways, PermissionGroup.locationWhenInUse] 'PERMISSION_LOCATION=0', ## dart: PermissionGroup.notification 'PERMISSION_NOTIFICATIONS=0', ## dart: PermissionGroup.mediaLibrary 'PERMISSION_MEDIA_LIBRARY=0', ## dart: PermissionGroup.sensors 'PERMISSION_SENSORS=0', ## dart: PermissionGroup.bluetooth 'PERMISSION_BLUETOOTH=0', ## dart: PermissionGroup.appTrackingTransparency 'PERMISSION_APP_TRACKING_TRANSPARENCY=0', ## dart: PermissionGroup.criticalAlerts 'PERMISSION_CRITICAL_ALERTS=0' ] end end end 公式だと使う権限の'#'を消せばいいみたいに書いてあるが、使わない権限も記述する必要がある模様。 0→使わない権限 1→使う権限 機能追加などで権限が必要となった場合にはinfo.plistだけではなく、podfileも0を1に変更する。 参考 公式:https://pub.dev/packages/permission_handler
  • このエントリーをはてなブックマークに追加
  • Qiitaで続きを読む

[Flutter][iOS] permission_handler 不要な権限リクエストを削除しないとApp Store Connectから怒られる

アプリをApp Store Connectに送信した際に(CI/CDで自動配布した際に)警告メールが届き、testflightでアプリをまくことができなかった 原因:どうやらAppleの静的解析ツールに引っかかっているらしい アプリのOS権限管理をpermission_handler 8.1.4+2にした後、ビルドしたバイナリをApp Store Connectに送信したら以下のようなめっちゃ長いメールが届いた。そんな場合の対処法をメモ 結論として、iOSのセットアップとして公式に記述されている方法と少し違った?ので注意が必要。 来たメール App Store Connect Dear Developer, We identified one or more issues with a recent delivery for your app, "hoge-app" 1.0.0. Please correct the following issues, then upload again. ITMS-90683: Missing Purpose String in Info.plist - Your app's code references one or more APIs that access sensitive user data. The app's Info.plist file should contain a NSContactsUsageDescription key with a user-facing purpose string explaining clearly and completely why your app needs the data. Starting Spring 2019, all apps submitted to the App Store that access user data are required to include a purpose string. If you're using external libraries or SDKs, they may reference APIs that require a purpose string. While your app might not use these APIs, a purpose string is still required. You can contact the developer of the library or SDK and request they release a version of their code that doesn't contain the APIs. Learn more (https://developer.apple.com/documentation/uikit/core_app/protecting_the_user_s_privacy). ITMS-90683: Missing Purpose String in Info.plist - Your app's code references one or more APIs that access sensitive user data. The app's Info.plist file should contain a NSCalendarsUsageDescription key with a user-facing purpose string explaining clearly and completely why your app needs the data. Starting Spring 2019, all apps submitted to the App Store that access user data are required to include a purpose string. If you're using external libraries or SDKs, they may reference APIs that require a purpose string. While your app might not use these APIs, a purpose string is still required. You can contact the developer of the library or SDK and request they release a version of their code that doesn't contain the APIs. Learn more (https://developer.apple.com/documentation/uikit/core_app/protecting_the_user_s_privacy). ITMS-90683: Missing Purpose String in Info.plist - Your app's code references one or more APIs that access sensitive user data. The app's Info.plist file should contain a NSAppleMusicUsageDescription key with a user-facing purpose string explaining clearly and completely why your app needs the data. Starting Spring 2019, all apps submitted to the App Store that access user data are required to include a purpose string. If you're using external libraries or SDKs, they may reference APIs that require a purpose string. While your app might not use these APIs, a purpose string is still required. You can contact the developer of the library or SDK and request they release a version of their code that doesn't contain the APIs. Learn more (https://developer.apple.com/documentation/uikit/core_app/protecting_the_user_s_privacy). ITMS-90683: Missing Purpose String in Info.plist - Your app's code references one or more APIs that access sensitive user data. The app's Info.plist file should contain a NSMotionUsageDescription key with a user-facing purpose string explaining clearly and completely why your app needs the data. Starting Spring 2019, all apps submitted to the App Store that access user data are required to include a purpose string. If you're using external libraries or SDKs, they may reference APIs that require a purpose string. While your app might not use these APIs, a purpose string is still required. You can contact the developer of the library or SDK and request they release a version of their code that doesn't contain the APIs. Learn more (https://developer.apple.com/documentation/uikit/core_app/protecting_the_user_s_privacy). ITMS-90683: Missing Purpose String in Info.plist - Your app's code references one or more APIs that access sensitive user data. The app's Info.plist file should contain a NSSpeechRecognitionUsageDescription key with a user-facing purpose string explaining clearly and completely why your app needs the data. Starting Spring 2019, all apps submitted to the App Store that access user data are required to include a purpose string. If you're using external libraries or SDKs, they may reference APIs that require a purpose string. While your app might not use these APIs, a purpose string is still required. You can contact the developer of the library or SDK and request they release a version of their code that doesn't contain the APIs. Learn more (https://developer.apple.com/documentation/uikit/core_app/protecting_the_user_s_privacy). Though you are not required to fix the following issues, we wanted to make you aware of them: ITMS-90683: Missing Purpose String in Info.plist - Your app's code references one or more APIs that access sensitive user data. The app's Info.plist file should contain a NSLocationWhenInUseUsageDescription key with a user-facing purpose string explaining clearly and completely why your app needs the data. Starting Spring 2019, all apps submitted to the App Store that access user data are required to include a purpose string. If you're using external libraries or SDKs, they may reference APIs that require a purpose string. While your app might not use these APIs, a purpose string is still required. You can contact the developer of the library or SDK and request they release a version of their code that doesn't contain the APIs. Learn more (https://developer.apple.com/documentation/uikit/core_app/protecting_the_user_s_privacy). Best regards, The App Store Team ...どうやら「アプリはたくさん権限をリクエストしているのに、Info.plistファイルに必要なキーが含まれていないですよ」という注意のよう。 しかし、これはpermission_handlerがデフォルトですべての権限のリクエストをしてしまっているせいなので、使う権限と使わない権限を明記してあげれば良し。 解決方法 ios/podfile post_install do |installer| installer.pods_project.targets.each do |target| flutter_additional_ios_build_settings(target) end end podfileの↑の部分に追記して以下のように変更! ios/podfile post_install do |installer| installer.pods_project.targets.each do |target| flutter_additional_ios_build_settings(target) target.build_configurations.each do |config| config.build_settings['GCC_PREPROCESSOR_DEFINITIONS'] ||= [ '$(inherited)', ## dart: PermissionGroup.calendar 'PERMISSION_EVENTS=0', ## dart: PermissionGroup.reminders 'PERMISSION_REMINDERS=0', ## dart: PermissionGroup.contacts 'PERMISSION_CONTACTS=0', ## dart: PermissionGroup.camera 'PERMISSION_CAMERA=1', ## dart: PermissionGroup.microphone 'PERMISSION_MICROPHONE=0', ## dart: PermissionGroup.speech 'PERMISSION_SPEECH_RECOGNIZER=0', ## dart: PermissionGroup.photos 'PERMISSION_PHOTOS=1', ## dart: [PermissionGroup.location, PermissionGroup.locationAlways, PermissionGroup.locationWhenInUse] 'PERMISSION_LOCATION=0', ## dart: PermissionGroup.notification 'PERMISSION_NOTIFICATIONS=0', ## dart: PermissionGroup.mediaLibrary 'PERMISSION_MEDIA_LIBRARY=0', ## dart: PermissionGroup.sensors 'PERMISSION_SENSORS=0', ## dart: PermissionGroup.bluetooth 'PERMISSION_BLUETOOTH=0', ## dart: PermissionGroup.appTrackingTransparency 'PERMISSION_APP_TRACKING_TRANSPARENCY=0', ## dart: PermissionGroup.criticalAlerts 'PERMISSION_CRITICAL_ALERTS=0' ] end end end 公式だと使う権限の'#'を消せばいいみたいに書いてあるが、使わない権限も記述する必要がある模様。 0→使わない権限 1→使う権限 機能追加などで権限が必要となった場合にはinfo.plistだけではなく、podfileも0を1に変更する。 参考 公式:https://pub.dev/packages/permission_handler
  • このエントリーをはてなブックマークに追加
  • Qiitaで続きを読む