fastlane / fastlane

🚀 The easiest way to automate building and releasing your iOS and Android apps
https://fastlane.tools
MIT License
39.3k stars 5.67k forks source link

`deliver` fails if IDFA is set #21998

Closed swiftty closed 2 months ago

swiftty commented 4 months ago

New Issue Checklist

Issue Description

Command executed
bundler: failed to load command: fastlane (/Users/vagrant/git/vendor/bundle/ruby/3.2.0/bin/fastlane)
/Users/vagrant/git/vendor/bundle/ruby/3.2.0/gems/fastlane-2.220.0/spaceship/lib/spaceship/connect_api/api_client.rb:223:in `handle_response': [!] The specified resource does not exist - The path provided does not match a defined resource type. (Spaceship::UnexpectedResponse)
    from /Users/vagrant/git/vendor/bundle/ruby/3.2.0/gems/fastlane-2.220.0/spaceship/lib/spaceship/connect_api/api_client.rb:125:in `post'
    from /Users/vagrant/git/vendor/bundle/ruby/3.2.0/gems/fastlane-2.220.0/spaceship/lib/spaceship/connect_api/tunes/tunes.rb:1116:in `post_idfa_declaration'
    from /Users/vagrant/.asdf/installs/ruby/3.2.3/lib/ruby/3.2.0/forwardable.rb:240:in `post_idfa_declaration'
    from /Users/vagrant/git/vendor/bundle/ruby/3.2.0/gems/fastlane-2.220.0/spaceship/lib/spaceship/connect_api/models/app_store_version.rb:256:in `create_idfa_declaration'
    from /Users/vagrant/git/vendor/bundle/ruby/3.2.0/gems/fastlane-2.220.0/deliver/lib/deliver/submit_for_review.rb:189:in `update_idfa'
    from /Users/vagrant/git/vendor/bundle/ruby/3.2.0/gems/fastlane-2.220.0/deliver/lib/deliver/submit_for_review.rb:23:in `submit!'
    from /Users/vagrant/git/vendor/bundle/ruby/3.2.0/gems/fastlane-2.220.0/deliver/lib/deliver/runner.rb:261:in `submit_for_review'

In post_idfa_declaration, fastlane calls POST /v1/idfaDeclarations, but api does not exists. I can't find idfaDeclarations in the apple documentation. https://developer.apple.com/documentation/appstoreconnectapi Perhaps already deprecated and removed?

miyoshitakaaki commented 4 months ago

I also encountered a similar error when using deliver action. I fixed it by changing add_id_info_uses_idfa in submission_information of deliver action from true to false.

    deliver(
      ...,
      submission_information: {
        "add_id_info_uses_idfa" => false,
      },
    )
crovax124 commented 4 months ago

I also encountered a similar error when using deliver action. I fixed it by changing add_id_info_uses_idfa in submission_information of deliver action from true to false.

    deliver(
      ...,
      submission_information: {
        "add_id_info_uses_idfa" => false,
      },
    )

for me this still happens ->

+----------------------------------------------------------------------------------------------------------+ | deliver 2.220.0 Summary | +----------------------------------------------------------------------------+-----------------------------+ | api_key | ******** | | skip_screenshots | true | | skip_metadata | false | | overwrite_screenshots | true | | sync_screenshots | false | | submit_for_review | true | | automatic_release | false | | force | true | | precheck_include_in_app_purchases | false | | submission_information.add_id_info_limits_tracking | true | | submission_information.add_id_info_serves_ads | false | | submission_information.add_id_info_tracks_action | true | | submission_information.add_id_info_tracks_install | true | | submission_information.add_id_info_uses_idfa | false | | submission_information.content_rights_has_rights | true | | submission_information.content_rights_contains_third_party_content | true | | submission_information.export_compliance_platform | ios | | submission_information.export_compliance_compliance_required | false | | submission_information.export_compliance_encryption_updated | false | | submission_information.export_compliance_uses_encryption | false | | submission_information.export_compliance_is_exempt | false | | submission_information.export_compliance_contains_third_party_cryptography | false | | submission_information.export_compliance_contains_proprietary_cryptography | false | | submission_information.export_compliance_available_on_french_store | false | | screenshots_path | ./fastlane/screenshots | | metadata_path | ./fastlane/metadata | | app_version | 1.0.0 | | app_identifier | ---- ------------| | ipa | Runner.ipa | | platform | ios | | edit_live | false | | use_live_version | false | | skip_binary_upload | false | | skip_app_version_update | false | | screenshot_processing_timeout | 3600 | | verify_only | false | | reject_if_possible | false | | version_check_wait_retry_limit | 7 | | phased_release | false | | reset_ratings | false | | run_precheck_before_submit | true | | precheck_default_rule_level | warn | | ignore_language_directory_validation | false | +----------------------------------------------------------------------------+--------------------

[13:34:33]: The specified resource does not exist - The path provided does not match a defined resource type. .../spaceship/connect_api/api_client.rb:223:inhandle_response': [!] The specified resource does not exist - The path provided does not match a defined resource type. (Spaceship::UnexpectedResponse) from .../spaceship/lib/spaceship/connect_api/api_client.rb:149:in delete' from .../spaceship/lib/spaceship/connect_api/tunes/tunes.rb:1133:indelete_idfa_declaration' from .../forwardable.rb:240:in delete_idfa_declaration' from.../spaceship/lib/spaceship/connect_api/models/idfa_declaration.rb:39:indelete!' `

fr0l commented 4 months ago

Seems it was deprecated in v1.5 by Apple and finally removed.

fr0l commented 4 months ago

Btw. It helps just to remove the add_id_info_uses_idfa setting from Deliverfile / deliver call

fr0l commented 4 months ago

I've created a PR https://github.com/fastlane/fastlane/pull/22003 here to delete the deprecated IDFA-related code. It's in progress. Probably I've deleted too much / not enough. Maybe some parts need to be just marked as @deprecated for time being. Let's see. still in progress.

the issue itself can be mitigated by:

the PR is just code removal

angelolloqui commented 3 months ago

I am afraid removing the parameter is not helping. When I get rid of it then I get another error complaining about the IDFA not present but required. I am blocked because no matter what I do it fails. By the way, removing it was fine in las build, but somehow it does no longer work for us. Anyone else with a similar issue?

gavrichards commented 3 months ago

I am afraid removing the parameter is not helping. When I get rid of it then I get another error complaining about the IDFA not present but required. I am blocked because no matter what I do it fails. By the way, removing it was fine in las build, but somehow it does no longer work for us. Anyone else with a similar issue?

Yes, I had the same. The only thing that seems to have worked for me so far is keeping it but setting it to false.

cgossain commented 3 months ago

I am afraid removing the parameter is not helping. When I get rid of it then I get another error complaining about the IDFA not present but required. I am blocked because no matter what I do it fails. By the way, removing it was fine in las build, but somehow it does no longer work for us. Anyone else with a similar issue?

Yes, I had the same. The only thing that seems to have worked for me so far is keeping it but setting it to false.

Confirmed this works for me too. Setting it to false without removing it works.