fastlane: `analyze_build_time` option causes sh: inherited: command not found, blocks xcpretty
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
Trying to use the analyze_build_time
option in gym
results in:
set -o pipefail && xcodebuild -workspace <redacted> OTHER_SWIFT_FLAGS="$(inherited) -Xfrontend -debug-time-function-bodies" archive | tee <redacted> | grep .[0-9]ms | grep -v ^0.[0-9]ms | sort -nr > culprits.txt | xcpretty
[09:32:06]: ▸ sh: inherited: command not found
… with no xcpretty output. Looks to me that the above command is not formatted properly…in particular the redirect to culprits.txt
precedes xcpretty
which looks wrong.
Complete output when running fastlane, including the stack trace and command used
You can use:
--capture_output
as the last commandline argument to get that collected for you
Environment
Please run fastlane env
and copy the output below. This will help us help you 👍
If you used --capture_output
option please remove this block - as it is already included there.
✅ fastlane environment ✅
Stack
Key | Value |
---|---|
OS | 10.12.6 |
Ruby | 2.4.1 |
Bundler? | false |
Git | git version 2.11.0 (Apple Git-81) |
Installation Source | /usr/local/bin/fastlane |
Host | Mac OS X 10.12.6 (16G29) |
Ruby Lib Dir | /usr/local/Cellar/ruby/2.4.1_1/lib |
OpenSSL Version | OpenSSL 1.0.2k 26 Jan 2017 |
Is contained | false |
Is homebrew | false |
Is installed via Fabric.app | false |
Xcode Path | /Applications/Xcode.app/Contents/Developer/ |
Xcode Version | 8.3.3 |
System Locale
Variable | Value | |
---|---|---|
LANG | en_US.UTF-8 | ✅ |
LC_ALL | ||
LANGUAGE |
fastlane gems
Gem | Version | Update-Status |
---|---|---|
fastlane | 2.54.3 | ✅ Up-To-Date |
Loaded fastlane plugins:
No plugins Loaded
Loaded gems
Gem | Version |
---|---|
did_you_mean | 1.1.0 |
slack-notifier | 1.5.1 |
CFPropertyList | 2.3.5 |
claide | 1.0.2 |
colored2 | 3.1.2 |
nanaimo | 0.2.3 |
xcodeproj | 1.5.1 |
rouge | 2.0.7 |
xcpretty | 0.2.8 |
terminal-notifier | 1.8.0 |
unicode-display_width | 1.3.0 |
terminal-table | 1.8.0 |
plist | 3.3.0 |
addressable | 2.5.2 |
multipart-post | 2.0.0 |
word_wrap | 1.0.0 |
public_suffix | 2.0.5 |
tty-screen | 0.5.0 |
babosa | 1.0.2 |
colored | 1.2 |
highline | 1.7.8 |
commander-fastlane | 4.4.5 |
excon | 0.58.0 |
faraday | 0.13.1 |
unf_ext | 0.0.7.4 |
unf | 0.1.4 |
domain_name | 0.5.20170404 |
http-cookie | 1.0.3 |
faraday-cookie_jar | 0.0.6 |
fastimage | 2.1.0 |
gh_inspector | 1.0.3 |
json | 2.0.2 |
mini_magick | 4.5.1 |
multi_json | 1.12.1 |
multi_xml | 0.6.0 |
rubyzip | 1.2.1 |
security | 0.1.3 |
xcpretty-travis-formatter | 0.0.4 |
dotenv | 2.2.1 |
bundler | 1.15.4 |
faraday_middleware | 0.12.2 |
uber | 0.1.0 |
declarative | 0.0.9 |
declarative-option | 0.1.0 |
representable | 3.0.4 |
retriable | 3.1.1 |
mime-types-data | 3.2016.0521 |
mime-types | 3.1 |
little-plugger | 1.1.4 |
logging | 2.2.2 |
jwt | 1.5.6 |
memoist | 0.16.0 |
os | 0.9.6 |
signet | 0.7.3 |
googleauth | 0.5.3 |
httpclient | 2.8.3 |
google-api-client | 0.13.3 |
io-console | 0.4.6 |
openssl | 2.0.3 |
generated on: 2017-08-29
About this issue
- Original URL
- State: closed
- Created 7 years ago
- Reactions: 4
- Comments: 20 (5 by maintainers)
Commits related to this issue
- #10187 Fix xcodebuild inherited command not found (#11739) When passing "analyze_build_time" parameter to "build_ios_app" aka gym, wrong xcodebuild flag "$(inherited)" is generated. $(inherited) is ... — committed to fastlane/fastlane by rkrim 6 years ago
- fixes #10187 — committed to RishabhTayal/fastlane by RishabhTayal 6 years ago
Greetings! Any updates on this issue?
@yzhong52 no, unfortunately, that doesn’t totally fix the issue. See https://github.com/fastlane/fastlane/issues/10187#issuecomment-363174719
Looking forward to trying the fix!
@taquitos I opened a PR for this fix: #12523.
Hi @KrauseFx $(inherited) is an environment variable where xcode checks the same variable from the project level and replace it before executing the build step, it must not be present from the command line. -Xfrontend is for telling xcode to display a UI warning (in the editor) -debug-time-function-bodies is for enabling the compilation timing for every function
Is this actually a fastlane issue? If you set this flag, all it does is append
to your build command, I’m not sure where those flags come from, but yah. How do we need to change the flags to make it work? I haven’t used it myself.
Sorry for the late response also