Open gianpaj opened 7 years ago
Is this all the output you get when running the lane?
Nothing else before or after ** ARCHIVE SUCCEEDED **
?
There's all the output from the cordova build command of course.
Here's a little bit more:
Touch build/device/App.app.dSYM
cd mobile/platforms/ios
export PATH="/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin:/Applications/Xcode.app/Contents/Developer/usr/bin:/Users/gianfranco/.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0/bin:/Users/gianfranco/.rbenv/versions/2.3.1/bin:/usr/local/Cellar/rbenv/1.1.1/libexec:/Users/gianfranco/.yarn/bin:/Users/gianfranco/.rbenv/shims:/usr/local/opt/qt/bin:/Users/gianfranco/google-cloud-sdk/bin:/Users/gianfranco/.fastlane/bin:/usr/local/opt/findutils/libexec/gnubin:/usr/local/sbin:/Users/gianfranco/bin:/usr/local/opt/openssl/bin:/Users/gianfranco/.nvm/versions/node/v6.11.3/bin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/opt/X11/bin:/opt/ImageMagick/bin:/usr/local/MacGPG2/bin:/Users/gianfranco/.composer/vendor/bin:/Users/gianfranco/Library/Android/sdk/platform-tools:/Users/gianfranco/Library/Android/sdk/tools:/Users/gianfranco/.themekit"
/usr/bin/touch -c platforms/ios/build/device/App.app.dSYM
** ARCHIVE SUCCEEDED **
Error: ENOENT: no such file or directory, open 'platforms/ios/App.xcworkspace/project.pbxproj'
/Users/gianfranco/.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0/gems/fastlane-2.67.0/fastlane_core/lib/fastlane_core/ui/interface.rb:143:in `shell_error!'
/Users/gianfranco/.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0/gems/fastlane-2.67.0/fastlane_core/lib/fastlane_core/ui/ui.rb:14:in `method_missing'
/Users/gianfranco/.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0/gems/fastlane-2.67.0/fastlane/lib/fastlane/helper/sh_helper.rb:56:in `sh_control_output'
/Users/gianfranco/.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0/gems/fastlane-2.67.0/fastlane/lib/fastlane/action.rb:98:in `sh'
/Users/gianfranco/.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0/gems/fastlane-plugin-cordova-1.0.0/lib/fastlane/plugin/cordova/actions/cordova_action.rb:94:in `build'
/Users/gianfranco/.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0/gems/fastlane-plugin-cordova-1.0.0/lib/fastlane/plugin/cordova/actions/cordova_action.rb:107:in `run'
/Users/gianfranco/.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0/gems/fastlane-2.67.0/fastlane/lib/fastlane/runner.rb:253:in `block (2 levels) in execute_action'
/Users/gianfranco/.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0/gems/fastlane-2.67.0/fastlane/lib/fastlane/actions/actions_helper.rb:50:in `execute_action'
/Users/gianfranco/.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0/gems/fastlane-2.67.0/fastlane/lib/fastlane/runner.rb:231:in `block in execute_action'
/Users/gianfranco/.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0/gems/fastlane-2.67.0/fastlane/lib/fastlane/runner.rb:227:in `chdir'
/Users/gianfranco/.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0/gems/fastlane-2.67.0/fastlane/lib/fastlane/runner.rb:227:in `execute_action'
/Users/gianfranco/.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0/gems/fastlane-2.67.0/fastlane/lib/fastlane/runner.rb:148:in `trigger_action_by_name'
/Users/gianfranco/.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0/gems/fastlane-2.67.0/fastlane/lib/fastlane/fast_file.rb:146:in `method_missing'
Fastfile:52:in `block (2 levels) in parsing_binding'
Hmm, I don't understand what is triggering this command that is failing...
You are not using the build_number
param, correct?
Inside the build output should be a generated cordova compile
command. Can you post that one and execute it manually, then post what happens?
Maybe really post (or attach a file containing) the complete output of the command with nothing missing.
There is a cordova compile:
[12:07:26]: $ cordova compile ios --release --device --packageType=app-store --developmentTeam=6TYG6TV7WQ --provisioningProfile=b8fb95a1-64df-425d-ad85-331d51fc25fe --
Here is the end of that command output:
[12:07:56]: ▸ cd /Users/gianfranco/App/mobile/platforms/ios
[12:07:56]: ▸ export PATH="/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin:/Applications/Xcode.app/Contents/Developer/usr/bin:/Users/gianfranco/.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0/bin:/Users/gianfranco/.rbenv/versions/2.3.1/bin:/usr/local/Cellar/rbenv/1.1.1/libexec:/Users/gianfranco/.yarn/bin:/Users/gianfranco/.rbenv/shims:/usr/local/opt/qt/bin:/Users/gianfranco/google-cloud-sdk/bin:/Users/gianfranco/.fastlane/bin:/usr/local/opt/findutils/libexec/gnubin:/usr/local/sbin:/Users/gianfranco/bin:/usr/local/opt/openssl/bin:/Users/gianfranco/.nvm/versions/node/v6.11.3/bin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/opt/X11/bin:/opt/ImageMagick/bin:/usr/local/MacGPG2/bin:/Users/gianfranco/.composer/vendor/bin:/Users/gianfranco/Library/Android/sdk/platform-tools:/Users/gianfranco/Library/Android/sdk/tools:/Users/gianfranco/.themekit"
[12:07:56]: ▸ export PRODUCT_TYPE=com.apple.product-type.application
[12:07:56]: ▸ builtin-validationUtility /Users/gianfranco/Library/Developer/Xcode/DerivedData/App-guwlrhjlnmimtjgznuegwhgvzgwd/Build/Intermediates.noindex/ArchiveIntermediates/App/InstallationBuildProductsLocation/Applications/App.app
[12:07:56]: ▸ Touch build/device/App.app.dSYM
[12:07:56]: ▸ cd /Users/gianfranco/App/mobile/platforms/ios
[12:07:56]: ▸ export PATH="/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin:/Applications/Xcode.app/Contents/Developer/usr/bin:/Users/gianfranco/.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0/bin:/Users/gianfranco/.rbenv/versions/2.3.1/bin:/usr/local/Cellar/rbenv/1.1.1/libexec:/Users/gianfranco/.yarn/bin:/Users/gianfranco/.rbenv/shims:/usr/local/opt/qt/bin:/Users/gianfranco/google-cloud-sdk/bin:/Users/gianfranco/.fastlane/bin:/usr/local/opt/findutils/libexec/gnubin:/usr/local/sbin:/Users/gianfranco/bin:/usr/local/opt/openssl/bin:/Users/gianfranco/.nvm/versions/node/v6.11.3/bin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/opt/X11/bin:/opt/ImageMagick/bin:/usr/local/MacGPG2/bin:/Users/gianfranco/.composer/vendor/bin:/Users/gianfranco/Library/Android/sdk/platform-tools:/Users/gianfranco/Library/Android/sdk/tools:/Users/gianfranco/.themekit"
[12:07:56]: ▸ /usr/bin/touch -c platforms/ios/build/device/App.app.dSYM
[12:07:56]: ▸ ** ARCHIVE SUCCEEDED **
[12:07:56]: ▸ Error: ENOENT: no such file or directory, open platforms/ios/App.xcworkspace/project.pbxproj'
+------------------------------------+----------------------------------+
| Lane Context |
+------------------------------------+----------------------------------+
| DEFAULT_PLATFORM | ios |
| PLATFORM_NAME | ios |
| LANE_NAME | ios release |
| SIGH_PROFILE_TYPE | app-store |
| MATCH_PROVISIONING_PROFILE_MAPPING | {"xyz.x"=>"match AppStore |
| | xyz.x"} |
+------------------------------------+----------------------------------+
[12:07:57]: Exit status of command 'cordova compile ios --release --device --packageType=app-store --developmentTeam=6TYG6TV7WQ --provisioningProfile=b8fb95a1-64df-425d-ad85-331d51fc25fe -- ' was 1 instead of 0.
Reading build config file:
Building project: mobile/platforms/ios/App.xcworkspace
Configuration: Release
Platform: device
Here is the full output (i ran it again. the lane might be slightly different): fastlane-output.txt.zip (i had to compress the 9.3MB output) 😲
I ran the cordova compile ios --release ...
command manually and it gave me the same error. I suppose that needs to work first.
So, I managed to make an .ipa
running the build
command:
$ cordova build ios --release --device --packageType=app-store --developmentTeam=xxx --provisioningProfile=xxx
...
Touch build/device/App.app.dSYM
cd platforms/ios
export PATH="/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin:/Applications/Xcode.app/Contents/Developer/usr/bin:/Users/gianfranco/.yarn/bin:/Users/gianfranco/.rbenv/shims:/usr/local/opt/qt/bin:/Users/gianfranco/google-cloud-sdk/bin:/Users/gianfranco/.fastlane/bin:/usr/local/opt/findutils/libexec/gnubin:/usr/local/sbin:/Users/gianfranco/bin:/usr/local/opt/openssl/bin:/Users/gianfranco/.nvm/versions/node/v6.11.3/bin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/opt/X11/bin:/opt/ImageMagick/bin:/usr/local/MacGPG2/bin:/Users/gianfranco/.composer/vendor/bin:/Users/gianfranco/Library/Android/sdk/platform-tools:/Users/gianfranco/Library/Android/sdk/tools:/Users/gianfranco/.themekit"
/usr/bin/touch -c platforms/ios/build/device/App.app.dSYM
** ARCHIVE SUCCEEDED **
Non-system Ruby in use. This may cause packaging to fail.
If you use RVM, please run `rvm use system`.
If you use chruby, please run `chruby system`.
2017-11-29 12:51:00.587 xcodebuild[63609:7028130] [MT] IDEDistribution: -[IDEDistributionLogging _createLoggingBundleAtPath:]: Created bundle at path '/var/folders/nc/scs6t9xj61l7rtzhz8cl48480000gn/T/App_2017-11-29_12-51-00.586.xcdistributionlogs'.
Exported App.xcarchive to: platforms/ios/build/device
** EXPORT SUCCEEDED **
$ ll platforms/ios/build/device/*.ipa
-rw-r--r-- 1 gianfranco staff 7.1M 29 Nov 12:51 platforms/ios/build/device/App.ipa
How do I tell the fastlane cordova plugin to run the build
command instead of compile
?
How do I tell the fastlane cordova plugin to run the build command instead of compile?
You don't as it runs prepare
and compile
, which is the same thing as build
- or at least should be (https://cordova.apache.org/docs/en/latest/reference/cordova-cli/#cordova-build-command: "Shortcut for cordova prepare + cordova compile") ;)
(i had to compress the 9.3MB output) 😲
Yeah, the Cordova build commands are a bit "chatty". I am still undecided if this is a good thing.
So, I managed to make an .ipa running the build command:
Just to confirm, replacing compile
from the command the plugin generated with build
enabled you to create a build manually, right?
You seem to have triggered a Cordova bug here somehow.
I looked into the error message again:
[12:07:56]: ▸ Error: ENOENT: no such file or directory, open '/Users/gianfranco/givebox/givebox.ui.mobile/platforms/ios/Givebox.xcworkspace/project.pbxproj'
This is indeed true, as the project.pbxproj
is inside the Givebox.xcodeproj
folder, not the .xcworkspace
. Could you check and confirm that please?
I just noticed Cordova Platforms : android 6.2.3 ios 4.5.3
.
cordova-ios 4.5.4 was release a few days ago. Could you maybe install that and try again?
(If this doesn't help, I think you should create an issue at issues.cordova.io showing your both commands, compile and build, and explain how one fails while the other succeeds)
This is indeed true, as the
project.pbxproj
is inside theApp.xcodeproj
folder, not the.xcworkspace
. Could you check and confirm that please?
Yes. That file does not exist:
$ ll platforms/ios/App.xcworkspace/
total 8
-rw-r--r-- 1 gianfranco staff 225B 9 Nov 16:59 contents.xcworkspacedata
drwxr-xr-x 3 gianfranco staff 102B 9 Nov 16:59 xcshareddata
drwxr-xr-x 3 gianfranco staff 102B 9 Nov 22:04 xcuserdata
I'll open a bug report for Cordova.
In the meantime I found a workaround if anybody is having the same issue:
$ cd your_ionic_or_cordova_project
$ ln -s platforms/ios/YOUR_IOS_APP.xcodeproj/project.pbxproj platforms/ios/YOUR_IOS_APP.xcworkspace/project.pbxproj
Post the link to the Cordova issue here when done, we'll debug this further over there. Thanks.
I think you're right, it's an issue somewhere with cordova.
https://issues.apache.org/jira/browse/CB-13618
FYI: upgrading to cordova-ios
4.5.4 did not fix the issue
@gianpaj i am having the same issue, the cordova ticket you linked does not seem to be progressing. I tried the following workaround as you suggested but it did not work.
$ cd your_ionic_or_cordova_project $ ln -s platforms/ios/YOUR_IOS_APP.xcodeproj/project.pbxproj platforms/ios/YOUR_IOS_APP.xcworkspace/project.pbxproj
@mevinDhun , sorry I don't know what it could be. I haven't used cordova in a while now.
Any suggestions?
Lane:
Any suggestions?
Building and archiving works when done from Xcode