fastlane: gym error on macOS Ventura 13.0, Xcode 14.0.1 & Xcode 14.1
New Issue Checklist
- Updated fastlane to the latest version
- I read the Contribution Guidelines
- I read docs.fastlane.tools
- I searched for existing GitHub issues
Issue Description
Command executed
lane :buildIpa do
gym(
scheme: "xxx",
output_name: "#{outputName}",
workspace: "xxx.xcworkspace",
export_method: "#{exportMethod}", # app-store、ad-hoc、development、enterprise
include_bitcode: false,
include_symbols: true,
silent: true,
clean: true,
configuration: "#{configurationType}",
xcargs: "#{xcargs}",
toolchain: "#{toolchain}",
skip_profile_detection: true,
export_options: {
compileBitcode: false,
provisioningProfiles: {
... ...
}
},
output_directory: "#{exportDir}",
)
end
Complete output when running fastlane, including the stack trace and command used
** ARCHIVE FAILED **
[09:48:17]: Exit status: 65
[09:48:17]:
[09:48:17]: Maybe the error shown is caused by using the wrong version of Xcode
[09:48:17]: Found multiple versions of Xcode in '/Applications/'
[09:48:17]: Make sure you selected the right version for your project
[09:48:17]: This build process was executed using '/Applications/Xcode.app'
[09:48:17]: If you want to update your Xcode path, either
[09:48:17]:
[09:48:17]: - Specify the Xcode version in your Fastfile
[09:48:17]: ▸ xcversion(version: "8.1") # Selects Xcode 8.1.0
[09:48:17]:
[09:48:17]: - Specify an absolute path to your Xcode installation in your Fastfile
[09:48:17]: ▸ xcode_select "/Applications/Xcode8.app"
[09:48:17]:
[09:48:17]: - Manually update the path using
[09:48:17]: ▸ sudo xcode-select -s /Applications/Xcode.app
+---------------+-------------------------+
| Build environment |
+---------------+-------------------------+
| xcode_path | /Applications/Xcode.app |
| gym_version | 2.210.1 |
| export_method | development |
| sdk | iPhoneOS16.0.sdk |
+---------------+-------------------------+
[09:48:17]: ⬆️ Check out the few lines of raw `xcodebuild` output above for potential hints on how to solve this error
[09:48:17]: 📋 For the complete and more detailed error log, check the full log at:
[09:48:17]: 📋 /Users/xxx/Library/Logs/gym/xxxx-xxxxx.log
[09:48:17]:
[09:48:17]: Your `export_method` in gym is defined as `development`
[09:48:17]: which might cause problems when signing your application
[09:48:17]: Are you sure want to build and export for development?
[09:48:17]: Please make sure to define the correct export methods when calling
[09:48:17]: gym in your Fastfile or from the command line
[09:48:17]:
[09:48:17]:
[09:48:17]: Looks like fastlane ran into a build/archive error with your project
[09:48:17]: It's hard to tell what's causing the error, so we wrote some guides on how
[09:48:17]: to troubleshoot build and signing issues: https://docs.fastlane.tools/codesigning/getting-started/
[09:48:17]: Before submitting an issue on GitHub, please follow the guide above and make
[09:48:17]: sure your project is set up correctly.
[09:48:17]: fastlane uses `xcodebuild` commands to generate your binary, you can see the
[09:48:17]: the full commands printed out in yellow in the above log.
[09:48:17]: Make sure to inspect the output above, as usually you'll find more error information there
Environment
<details><summary>✅ fastlane environment ✅</summary>
### Stack
| Key | Value |
| --------------------------- | ------------------------------------------- |
| OS | 13.0 |
| Ruby | 3.0.0 |
| Bundler? | false |
| Git | git version 2.37.0 (Apple Git-136) |
| Installation Source | /usr/local/bin/fastlane |
| Host | macOS 13.0 (22A380) |
| Ruby Lib Dir | ~/.rvm/rubies/ruby-3.0.0/lib |
| OpenSSL Version | OpenSSL 1.1.1q 5 Jul 2022 |
| Is contained | false |
| Is homebrew | false |
| Is installed via Fabric.app | false |
| Xcode Path | /Applications/Xcode.app/Contents/Developer/ |
| Xcode Version | 14.0.1 |
| Swift Version | 5.7 |
### System Locale
| Variable | Value | |
| -------- | ----------- | - |
| LANG | zh_CN.UTF-8 | ✅ |
| LC_ALL | | |
| LANGUAGE | | |
### fastlane gems
| Gem | Version | Update-Status |
| -------- | ------- | ------------- |
| fastlane | 2.210.1 | ✅ Up-To-Date |
### Loaded fastlane plugins:
| Plugin | Version | Update-Status |
| --------------------- | ------- | ------------- |
| fastlane-plugin-pgyer | 0.2.4 | ✅ Up-To-Date |
| fastlane-plugin-badge | 1.5.0 | ✅ Up-To-Date |
<details><summary><b>Loaded gems</b></summary>
| Gem | Version |
| ------------------------------- | ------------ |
| did_you_mean | 1.5.0 |
| atomos | 0.1.3 |
| CFPropertyList | 3.0.5 |
| claide | 1.1.0 |
| colored2 | 3.1.2 |
| nanaimo | 0.3.0 |
| xcodeproj | 1.22.0 |
| rouge | 2.0.7 |
| xcpretty | 0.3.0 |
| terminal-notifier | 2.0.0 |
| unicode-display_width | 1.8.0 |
| terminal-table | 1.8.0 |
| plist | 3.6.0 |
| public_suffix | 4.0.7 |
| addressable | 2.8.1 |
| multipart-post | 2.0.0 |
| word_wrap | 1.0.0 |
| optparse | 0.1.1 |
| tty-screen | 0.8.1 |
| tty-cursor | 0.7.1 |
| tty-spinner | 0.9.3 |
| artifactory | 3.0.15 |
| babosa | 1.0.4 |
| colored | 1.2 |
| highline | 2.0.3 |
| commander | 4.6.0 |
| excon | 0.93.1 |
| faraday-em_http | 1.0.0 |
| faraday-em_synchrony | 1.0.0 |
| faraday-excon | 1.1.0 |
| faraday-httpclient | 1.0.1 |
| faraday-multipart | 1.0.4 |
| faraday-net_http | 1.0.1 |
| faraday-net_http_persistent | 1.2.0 |
| faraday-patron | 1.0.0 |
| faraday-rack | 1.0.0 |
| faraday-retry | 1.0.3 |
| ruby2_keywords | 0.0.5 |
| faraday | 1.10.2 |
| unf_ext | 0.0.8.2 |
| unf | 0.1.4 |
| domain_name | 0.5.20190701 |
| http-cookie | 1.0.5 |
| faraday-cookie_jar | 0.0.7 |
| faraday_middleware | 1.2.0 |
| fastimage | 2.2.6 |
| gh_inspector | 1.1.3 |
| mini_magick | 4.11.0 |
| naturally | 2.2.1 |
| rubyzip | 2.3.2 |
| security | 0.1.3 |
| xcpretty-travis-formatter | 1.0.1 |
| dotenv | 2.8.1 |
| bundler | 2.2.3 |
| simctl | 1.6.8 |
| jwt | 2.5.0 |
| uber | 0.1.0 |
| declarative | 0.0.20 |
| trailblazer-option | 0.1.2 |
| representable | 3.2.0 |
| retriable | 3.1.2 |
| mini_mime | 1.1.2 |
| memoist | 0.16.2 |
| multi_json | 1.15.0 |
| os | 1.1.4 |
| signet | 0.17.0 |
| googleauth | 1.3.0 |
| httpclient | 2.8.3 |
| webrick | 1.7.0 |
| google-apis-core | 0.9.1 |
| google-apis-playcustomapp_v1 | 0.12.0 |
| google-apis-androidpublisher_v3 | 0.29.0 |
| google-cloud-env | 1.6.0 |
| google-cloud-errors | 1.3.0 |
| google-cloud-core | 1.6.0 |
| google-apis-iamcredentials_v1 | 0.15.0 |
| google-apis-storage_v1 | 0.19.0 |
| digest-crc | 0.6.4 |
| google-cloud-storage | 1.43.0 |
| emoji_regex | 3.2.3 |
| jmespath | 1.6.1 |
| aws-partitions | 1.651.0 |
| aws-eventstream | 1.2.0 |
| aws-sigv4 | 1.5.2 |
| aws-sdk-core | 3.166.0 |
| aws-sdk-kms | 1.59.0 |
| aws-sdk-s3 | 1.117.1 |
| tsort | 0.1.0 |
| set | 1.0.1 |
| uri | 0.10.1 |
| rexml | 3.2.5 |
| json | 2.6.2 |
| rake | 13.0.6 |
| forwardable | 1.3.2 |
| logger | 1.4.3 |
| pathname | 0.1.0 |
| shellwords | 0.1.0 |
| cgi | 0.2.0 |
| date | 3.1.0 |
| timeout | 0.1.1 |
| stringio | 3.0.0 |
| securerandom | 0.1.0 |
| openssl | 2.2.0 |
| io-nonblock | 0.1.0 |
| ipaddr | 1.2.2 |
| io-wait | 0.1.0 |
| zlib | 1.1.0 |
| resolv | 0.2.0 |
| digest | 3.0.0 |
| time | 0.1.0 |
| open-uri | 0.1.0 |
| mutex_m | 0.1.1 |
| net-protocol | 0.1.0 |
| net-smtp | 0.2.1 |
| ostruct | 0.3.1 |
| english | 0.7.1 |
| erb | 2.2.0 |
| strscan | 3.0.0 |
| abbrev | 0.1.0 |
| io-console | 0.5.6 |
| tempfile | 0.1.1 |
| delegate | 0.2.0 |
| fileutils | 1.5.0 |
| tmpdir | 0.1.1 |
| base64 | 0.1.0 |
| singleton | 0.1.1 |
| open3 | 0.1.1 |
| nkf | 0.1.0 |
| prettyprint | 0.1.0 |
| pp | 0.1.0 |
| find | 0.1.0 |
| yaml | 0.1.1 |
| psych | 3.3.0 |
| fastlane-plugin-pgyer | 0.2.4 |
| badge | 0.13.0 |
| fastlane-plugin-badge | 1.5.0 |
</details>
*generated on:* **2022-11-02**
</details>
I encounter this problem after I upgrade my mac os to Ventura 13.0. But It works with Xcode14.0.1 on macOS 12.6.1.
It works for about a few minutes on my project till it fails. I can’t find any useful error message that told me where is the error. It seems that gym fails before the ‘code sign’ action I suppose.
About this issue
- Original URL
- State: open
- Created 2 years ago
- Reactions: 7
- Comments: 37
This seemed to solve the problem for our app by adding this to the Podfile. Hope this helps someone with the pending apple requirement starting in April to build on xcode 14
any update? same issue
Hi,
Not working too with Xcode 14.2, any update?
Thanks
Hi, Could someone (@joshdholtz?) from Fastlane team give us any updates? I have tried all suggested workarounds without success from 6 months on my CI… It is really a major problem to me for now on 🙏
My last error trace
Thank you very much
I was also facing the same
Exit status: 65problem with Bitrise’s “Xcode 14.1.x, on macOS Monterey 12.5” stack. However, I was able to work around it by specifying"CODE_SIGN_STYLE='Manual'"in thexcargsof the gym.Unfortunately didn’t work for me 😦
I have the same issue, I cannot build ipa via gym xCode Version 14.3 (14E222b) MacOS Ventura 13.3 latest version of pods, ruby and fastlane
@fbaumgart I only have one Xcode on my mac. This is not the case. As I described above, it works before I upgrade my mac os to Ventura 13.0. And my colleagues also encounter the same case.
Not working on Xcode 14.3. Facing same issue.
i confirm, this solution worked for me.
You need to add some xcargs to the Gym command (either in your Gymfile, or in the gym() command in your lane). Here’s what I added:
gym( [...], xcargs: "CODE_SIGN_STYLE=Manual DEVELOPMENT_TEAM=XXX" )+1 monterey 12.6.1 keep fail too on Bitrise “Xcode 14.1.x, on macOS Monterey 12.5” stack
Finally, I’ve resolved this error by changing some SDKs from
frameworktoxcframeworkas mentioned below this issue https://github.com/apple/swift-driver/issues/1271.Those SDKs showed error info with
SwiftDriver compilation error: com.apple.xcode.tools.swift.compiler is not absolutein the build log.If the SDK you linked in your project doesn’t offer
xcframework. You can use the framework file to generate thexcframeworkfile withlipoandxcodebuild -create-xcframeworktools.Thanks for your information. I found that it works when I build with
ad-hocorappstoreenvironment. It only failed with thedevelopmentenvironment. I don’t usematchaction in our project. I’ll continue to dig into what causes this error.This one might help
https://stackoverflow.com/a/75979879/1314468
I ❤️ U @tjbenton
Hi, any update on this issue? Thanks.
Sorry, I don’t use Flutter in my project. I’m not sure if it’s the
gyms issue. I can only make sure that if you have this error messageSwiftDriver compilation error: com.apple.xcode.tools.swift.compilerin the build log as shown below image, thegymmay output anArchive Failedmessage and exit.This is the case that I encountered. And I can fix it with the solution I mentioned above.
It seems like some message mentioned on issue apple/swift#20784 is useful for you.