fastlane: Unable to infer app version on CircleCI

New Issue Checklist

Issue Description

Sometime in the last month, uploading to iTunes Connect stopped working with an error about being unable to infer the app version. I did a little digging and am thinking it may have started after the IPA file analyzer was refactored in #7587. Manually uploading the archive works fine and the CFBundleShortVersionString is set in the IPA’s Info.plist.

Complete output when running fastlane, including the stack trace and command used
+----------------------+-----------------------------------+
|                  Summary for gym 2.16.0                  |
+----------------------+-----------------------------------+
| scheme               | Production                        |
| configuration        | Production                        |
| include_symbols      | true                              |
| output_directory     | /tmp/circle-artifacts.4QRBirO     |
| output_name          | OurApp                            |
| toolchain            | swift_3_1                         |
| export_method        | app-store                         |
| workspace            | ./OurApp.xcworkspace              |
| destination          | generic/platform=iOS              |
| clean                | false                             |
| silent               | false                             |
| use_legacy_build_api | false                             |
| buildlog_path        | /tmp/circle-artifacts.4QRBirO/gym |
| xcode_path           | /Applications/Xcode-8.2.app       |
+----------------------+-----------------------------------+

[10:35:08]: Successfully exported and compressed dSYM file
[10:35:08]: Successfully exported and signed the ipa file:
[10:35:08]: /tmp/circle-artifacts.4QRBirO/OurApp.ipa
[10:35:08]: ------------------------------
[10:35:08]: --- Step: backup_xcarchive ---
[10:35:08]: ------------------------------
[10:35:08]: Compressing /Users/distiller/Library/Developer/Xcode/Archives/2017-02-14/OurApp 2017-02-14 10.15.45.xcarchive
[10:35:08]: $ cd "/Users/distiller/Library/Developer/Xcode/Archives/2017-02-14" && zip -r -X "/var/folders/jm/fw86rxds0xn69sk40d18y69m0000gp/T/backup_xcarchive20170214-9522-o1mskh/OurApp 2017-02-14 10.15.45.xcarchive.zip" "OurApp 2017-02-14 10.15.45.xcarchive" > /dev/null
[10:35:32]: ---------------------
[10:35:32]: --- Step: deliver ---
[10:35:32]: ---------------------
[10:35:32]: Login to iTunes Connect (fastlane@company.com)
[10:35:37]: Login successful
+-----------------------+--------------------------------------------------------------------------+
|                                           Lane Context                                           |
+-----------------------+--------------------------------------------------------------------------+
| PLATFORM_NAME         |                                                                          |
| LANE_NAME             | send_to_itunes                                                           |
| SIGH_PROFILE_TYPE     | app-store                                                                |
| IPA_OUTPUT_PATH       | /tmp/circle-artifacts.4QRBirO/OurApp.ipa                                 |
| DSYM_OUTPUT_PATH      | /tmp/circle-artifacts.4QRBirO/OurApp.app.dSYM.zip                        |
| XCODEBUILD_ARCHIVE    | /Users/distiller/Library/Developer/Xcode/Archives/2017-02-14/OurApp 2... |
| BACKUP_XCARCHIVE_FILE | /tmp/circle-artifacts.4QRBirO/OurApp 2017-02-14 10.15.45.xcarchive.zip   |
+-----------------------+--------------------------------------------------------------------------+
[10:35:39]: Could not infer your app's version

Relevant portion of our Fastfile:

lane :send_to_itunes do

  run_buildnumber_script

  team_id = "ABCDEFG"
  app_identifier = "com.company.OurApp"
  force_match_appstore

  install_match(team_id, app_identifier)

  gym(
    scheme: 'Production',
    configuration: 'Production',
    include_symbols: true,
    output_directory: ENV['CIRCLE_ARTIFACTS'],
    output_name: 'OurApp.ipa',
    toolchain: :swift_3_1
  )

  save_archive_to_artifacts

  deliver(
    username: ENV['DELIVER_USER'],
    app_identifier: ENV['DELIVER_APP_IDENTIFER'],
    app: ENV['DELIVER_APPLE_ID'],
    ipa: "#{ENV['CIRCLE_ARTIFACTS']}/OurApp.ipa",
    force: true,
    skip_metadata: true
  )
end

Environment

CircleCI

<details><summary>✅ fastlane environment ✅</summary>

### Stack

| Key                 | Value                                                    |
| ------------------- | -------------------------------------------------------- |
| OS                  | 10.11.6                                                  |
| Ruby                | 2.3.1                                                    |
| Bundler?            | true                                                     |
| Git                 | git version 2.10.2                                       |
| Installation Source | ~/r101-ios-teacher/vendor/bundle/ruby/2.3.0/bin/fastlane |
| Host                | Mac OS X 10.11.6 (15G1108)                               |
| Ruby Lib Dir        | /opt/rubies/ruby-2.3.1/lib                               |
| OpenSSL Version     | OpenSSL 1.0.2j  26 Sep 2016                              |
| Is contained        | false                                                    |
| Is homebrew         | false                                                    |
| Xcode Path          | /Applications/Xcode-8.2.app/Contents/Developer/          |
| Xcode Version       | 8.2.1                                                    |


### System Locale

| Variable | Value       |   |
| -------- | ----------- | - |
| LANG     | en_US.UTF-8 | ✅ |
| LC_ALL   |             |   |
| LANGUAGE |             |   |

### fastlane gems

| Gem                 | Version | Update-Status |
| ------------------- | ------- | ------------- |
| fastlane            | 2.16.0  | ✅ Up-To-Date  |
| credentials_manager | 1.0.0   | ✅ Up-To-Date  |
| spaceship           | 1.0.0   | ✅ Up-To-Date  |


### Loaded fastlane plugins:

**No plugins Loaded**


<details><summary><b>Loaded gems</b></summary>

| Gem                       | Version      |
| ------------------------- | ------------ |
| did_you_mean              | 1.0.2        |
| bundler                   | 1.13.6       |
| io-console                | 0.4.6        |
| rake                      | 10.4.2       |
| CFPropertyList            | 2.3.5        |
| i18n                      | 0.8.0        |
| json                      | 1.8.6        |
| minitest                  | 5.10.1       |
| thread_safe               | 0.3.5        |
| tzinfo                    | 1.2.2        |
| activesupport             | 4.2.7.1      |
| public_suffix             | 2.0.5        |
| addressable               | 2.5.0        |
| babosa                    | 1.0.2        |
| claide                    | 1.0.1        |
| clamp                     | 0.6.5        |
| fuzzy_match               | 2.0.4        |
| nap                       | 1.1.0        |
| cocoapods-core            | 1.0.1        |
| cocoapods-deintegrate     | 1.0.1        |
| cocoapods-downloader      | 1.1.3        |
| cocoapods-plugins         | 1.0.0        |
| cocoapods-search          | 1.0.0        |
| cocoapods-stats           | 1.0.0        |
| netrc                     | 0.7.8        |
| cocoapods-trunk           | 1.1.2        |
| cocoapods-try             | 1.1.0        |
| colored                   | 1.2          |
| escape                    | 0.0.4        |
| fourflusher               | 0.3.2        |
| molinillo                 | 0.4.5        |
| nanaimo                   | 0.2.3        |
| xcodeproj                 | 1.4.2        |
| cocoapods                 | 1.0.1        |
| highline                  | 1.7.8        |
| commander                 | 4.4.3        |
| dotenv                    | 2.2.0        |
| excon                     | 0.55.0       |
| multipart-post            | 2.0.0        |
| faraday                   | 0.11.0       |
| unf_ext                   | 0.0.7.2      |
| unf                       | 0.1.4        |
| domain_name               | 0.5.20161129 |
| http-cookie               | 1.0.3        |
| faraday-cookie_jar        | 0.0.6        |
| faraday_middleware        | 0.11.0.1     |
| fastimage                 | 2.0.1        |
| gh_inspector              | 1.0.3        |
| jwt                       | 1.5.6        |
| little-plugger            | 1.1.4        |
| multi_json                | 1.12.1       |
| logging                   | 2.1.0        |
| memoist                   | 0.15.0       |
| os                        | 0.9.6        |
| signet                    | 0.7.3        |
| googleauth                | 0.5.1        |
| httpclient                | 2.8.3        |
| hurley                    | 0.2          |
| mime-types                | 2.99.3       |
| uber                      | 0.0.15       |
| representable             | 2.3.0        |
| retriable                 | 2.1.0        |
| google-api-client         | 0.9.28       |
| mini_magick               | 4.5.1        |
| multi_xml                 | 0.6.0        |
| plist                     | 3.2.0        |
| rubyzip                   | 1.2.1        |
| security                  | 0.1.3        |
| slack-notifier            | 1.5.1        |
| terminal-notifier         | 1.7.1        |
| unicode-display_width     | 1.1.3        |
| terminal-table            | 1.7.3        |
| tty-screen                | 0.5.0        |
| word_wrap                 | 1.0.0        |
| rouge                     | 1.11.1       |
| xcpretty                  | 0.2.4        |
| xcpretty-travis-formatter | 0.0.4        |
| credentials_manager       | 1.0.0        |
| mini_portile2             | 2.1.0        |
| nokogiri                  | 1.6.8.1      |
| rest-client               | 1.8.0        |
| slather                   | 2.3.0        |

About this issue

  • Original URL
  • State: closed
  • Created 7 years ago
  • Comments: 29 (2 by maintainers)

Commits related to this issue

Most upvoted comments

@mfurtak I want the stack of the previous error, to see where the issue fails within the ipa analysis.