Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unable to promote Testflight release "Cannot submit for review" #334

Open
stefan-schweiger opened this issue Aug 23, 2023 · 3 comments
Open

Comments

@stefan-schweiger
Copy link

stefan-schweiger commented Aug 23, 2023

Required Information

Entering this information will route you directly to the right team and expedite traction.

Question, Bug, or Feature?
Type: Bug

ask Name: AppStorePromote

Environment

Azure Pipelines -Hosted Agent (macos-12)

Issue Description

I have released my app successfully to the App Store with the AppStoreRelease task:

- task: AppStoreRelease@1
  inputs:
    serviceEndpoint: 'app-store-publish'
    releaseTrack: 'TestFlight'
    appIdentifier: '$(APP_IDENTIFIER)'
    appType: 'iOS'
    ipaPath: '$(Pipeline.Workspace)/appBuild/*.ipa'
    appSpecificId: '$(APP_APPLE_ID)'

When I try now promote this version with AppStorePromote I doesn't work with the error [!] Cannot submit for review - could not find an editable version for 'IOS':

- task: AppStorePromote@1
  inputs:
    serviceEndpoint: 'app-store-publish'
    appIdentifier: '$(APP_IDENTIFIER)'
    chooseBuild: 'Specify'
    buildNumber: '$(Build.BuildNumber)'
    shouldAutoRelease: true

Task logs

==============================================================================
Task         : Apple App Store Promote
Description  : Release a build from iTunes Connect to the Apple App Store
Version      : 1.218.0
Author       : Microsoft Corporation
Help         : [More Information](https://marketplace.visualstudio.com/items?itemName=ms-vsclient.app-store)
==============================================================================
/usr/local/opt/[email protected]/bin/gem install fastlane
Successfully installed fastlane-2.214.0
Parsing documentation for fastlane-2.214.0
Installing ri documentation for fastlane-2.214.0
Done installing documentation for fastlane after 21 seconds
1 gem installed
/usr/local/opt/[email protected]/bin/gem update fastlane -i /Users/runner/.gem-cache
Updating installed gems
Nothing to update
Gems already up-to-date: fastlane
Precheck will not check In-app purchases because Fastlane doesn't support it with the App Store Connect API Key.
/usr/local/lib/ruby/gems/3.0.0/bin/fastlane deliver submit_build --precheck_include_in_app_purchases false --api_key_path /Users/runner/work/_temp/api_key***.json -a ###REDACTED### -n 20230823.1 --skip_binary_upload true --skip_metadata true --skip_screenshots true --automatic_release --force
[09:02:02]: Get started using a Gemfile for fastlane https://docs.fastlane.tools/getting-started/ios/setup/#use-a-gemfile
[09:02:05]: Sending anonymous analytics information
[09:02:05]: Learn more at https://docs.fastlane.tools/#metrics
[09:02:05]: No personal or sensitive data is sent.
[09:02:05]: You can disable this by adding `opt_out_usage` at the top of your Fastfile
[09:02:05]: Creating authorization token for App Store Connect API

+--------------------------------------+-------------------------------------------------+
|                                deliver 2.214.0 Summary                                 |
+--------------------------------------+-------------------------------------------------+
| precheck_include_in_app_purchases    | false                                           |
| api_key_path                         | /Users/runner/work/_temp/api_key***.json        |
| app_identifier                       | ###REDACTED###                                  |
| build_number                         | 20230823.1                                      |
| skip_binary_upload                   | true                                            |
| skip_metadata                        | true                                            |
| skip_screenshots                     | true                                            |
| automatic_release                    | true                                            |
| force                                | true                                            |
| submit_for_review                    | true                                            |
| screenshots_path                     | ./screenshots                                   |
| metadata_path                        | ./metadata                                      |
| platform                             | ios                                             |
| edit_live                            | false                                           |
| use_live_version                     | false                                           |
| skip_app_version_update              | false                                           |
| overwrite_screenshots                | false                                           |
| sync_screenshots                     | false                                           |
| verify_only                          | false                                           |
| reject_if_possible                   | false                                           |
| phased_release                       | false                                           |
| reset_ratings                        | false                                           |
| run_precheck_before_submit           | true                                            |
| precheck_default_rule_level          | warn                                            |
| ignore_language_directory_validation | false                                           |
+--------------------------------------+-------------------------------------------------+

[09:02:06]: Running precheck before submitting to review, if you'd like to disable this check you can set run_precheck_before_submit to false
[09:02:06]: Making sure we pass precheck 👮‍♀️ 👮 before we submit  🛫

+--------------------------+-------------------------------------------------+
|                        Summary for precheck 2.214.0                        |
+--------------------------+-------------------------------------------------+
| default_rule_level       | warn                                            |
| include_in_app_purchases | false                                           |
| app_identifier           | ###REDACTED###                                  |
| api_key_path             | /Users/runner/work/_temp/api_key***.json        |
| platform                 | ios                                             |
| use_live                 | false                                           |
+--------------------------+-------------------------------------------------+

[09:02:06]: Creating authorization token for App Store Connect API
[09:02:06]: Checking app for precheck rule violations
[09:02:14]: ✅  Passed: No negative  sentiment
[09:02:14]: ✅  Passed: No placeholder text
[09:02:14]: ✅  Passed: No mentioning  competitors
[09:02:14]: ✅  Passed: No future functionality promises
[09:02:14]: ✅  Passed: No words indicating test content
[09:02:14]: ✅  Passed: No curse words
[09:02:14]: ✅  Passed: No words indicating your IAP is free
[09:02:14]: ✅  Passed: Incorrect, or missing copyright date
[09:02:17]: ✅  Passed: No broken urls
[09:02:17]: precheck 👮‍♀️ 👮  finished without detecting any potential problems 🛫

[!] Cannot submit for review - could not find an editable version for 'IOS'
##[error]Error: The process '/usr/local/lib/ruby/gems/3.0.0/bin/fastlane' failed with exit code 1
Finishing: AppStorePromote
@max-zaytsev
Copy link

@stefan-schweiger Is this issue still relevant?

@stefan-schweiger
Copy link
Author

@max-zaytsev yes, this is still relevant. My guess is that I'm maybe missing some fastlane config? But it's a bit hard to tell since the Promote task is a bit under documented in my opinion :/

@ck-tpt
Copy link

ck-tpt commented Jan 31, 2025

I resolved this after quite some time owing to the lack of documentation, but the submit_for_review: true means the uploaded build is not editable. This blocks the promotion to Production Track. To solve this in your upload to TestFlight AppStoreRelease task add shouldSubmitForReview: false in the AppStoreRelease task.

After that, it failed again in the AppStorePromote task with error:
The provided entity is missing a required attribute - You must provide a value for the attribute 'whatsNew' with this request

Fixing this required me submitting --release_notes in fastlaneArguments, after which I decided to control the all aspects of the metadata in the pipeline. You need to provide these as a hash with language codes as keys. I only have one but you could refer to file with all of them in your src control if you needed.

My final form of AppStoreRelease and AppStorePromote looked like the below, hope this helps you.

- task: AppStoreRelease@1
  inputs:
    appType: iOS
    ipaPath: "$(Pipeline.Workspace)/my-app.ipa"
    releaseTrack: TestFlight
    serviceEndpoint: MY-SERVICE-CONNECTION
    shouldSkipWaitingForProcessing: true
    shouldSkipSubmission: false # to allow for submission in AppStorePromote task
    shouldSubmitForReview: false # to make release editable

- task: AppStorePromote@1
  inputs:
    appIdentifier: "com.myapp.mobile"
    buildNumber: "$(VersionNumber)"
    chooseBuild: "Specify" # to prevent race conditions
    sourceTrack: "TestFlight"
    destinationTrack: "Production"
    serviceEndpoint: "MY-SERVICE-CONNECTION"
    shouldAutoRelease: true # once reviewed automatically releases it.
    shouldSubmitForReview: true # submit for review
    fastlaneArguments: >
      --app_version "$(VersionNumber)"
      --release_notes "{\"en-US\": \"Bug fixes and performance improvements.\"}"
      --description "{\"en-US\": \"$(Description)\"}"
      --keywords "{\"en-US\": \"$(KeyWords)\"}"
      --marketing_url "{\"en-US\": \"$(MarketingUrl)\"}"
      --support_url "{\"en-US\": \"$(SupportUrl)\"}"
      --privacy_url "{\"en-US\": \"$(PrivacyUrl)\"}"

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants