Coder Social home page Coder Social logo

fastlane / fastlane-plugin-firebase_app_distribution Goto Github PK

View Code? Open in Web Editor NEW
162.0 44.0 30.0 383 KB

fastlane plugin for Firebase App Distribution. https://firebase.google.com/docs/app-distribution

License: MIT License

Ruby 100.00%
firebase firebase-app-distribution fastlane fastlane-plugin

fastlane-plugin-firebase_app_distribution's Introduction

Firebase App Distribution Firebase App Distribution

fastlane Plugin Badge

Firebase App Distribution makes distributing your apps to trusted testers painless. By getting your apps onto testers' devices quickly, you can get feedback early and often. To learn more about Firebase App Distribution, go here.

Getting Started

Run tests for this plugin

To run both the tests, and code style validation, run

rake

To automatically fix many of the styling issues, use

rubocop -a

Issues and Feedback

For any other issues and feedback about this plugin, please submit it to this repository.

Troubleshooting

If you have trouble using plugins, check out the Plugins Troubleshooting guide.

Using fastlane Plugins

For more information about how the fastlane plugin system works, check out the Plugins documentation.

About fastlane

fastlane is the easiest way to automate beta deployments and releases for your iOS and Android apps. To learn more, check out fastlane.tools.

fastlane-plugin-firebase_app_distribution's People

Contributors

adrianha avatar alonsosalasinfante avatar brownoxford avatar cy-4ah avatar fxsalazar avatar garry-jeromson avatar jeremydurham avatar kaibolay avatar lfkellogg avatar maesterchestnut avatar manny-jimenez avatar rebehe avatar robotex avatar snatchev avatar spatenotte avatar tagboola avatar tenhishadow avatar tonybaroneee avatar yoshifujit avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

fastlane-plugin-firebase_app_distribution's Issues

unknown keyword: default_value_dynamic

Hi,

I've just opened an issue on the main fastlane project and just realised it may well be better fixed here: fastlane/fastlane#15602

Everything works fine up until the firebase_app_distribution step. I then get the following:

[16:23:06]: ---------------------------------------
[16:23:06]: --- Step: firebase_app_distribution ---
[16:23:06]: ---------------------------------------
[16:23:06]: You passed invalid parameters to 'firebase_app_distribution'.
[16:23:06]: Check out the error below and available options by running `fastlane action firebase_app_distribution`

with the following stack trace:

/Users/xxx/.fastlane/bin/bundle/lib/ruby/gems/2.2.0/gems/fastlane-2.28.3/fastlane_core/lib/fastlane_core/configuration/config_item.rb:58:in `initialize': [!] unknown keyword: default_value_dynamic (ArgumentError)
from /Users/xxx/.fastlane/bin/bundle/lib/ruby/gems/2.2.0/gems/fastlane-plugin-firebase_app_distribution-0.1.4/lib/fastlane/plugin/firebase_app_distribution/actions/firebase_app_distribution_action.rb:65:in `new'
from /Users/xxx/.fastlane/bin/bundle/lib/ruby/gems/2.2.0/gems/fastlane-plugin-firebase_app_distribution-0.1.4/lib/fastlane/plugin/firebase_app_distribution/actions/firebase_app_distribution_action.rb:65:in `available_options'
from /Users/xxx/.fastlane/bin/bundle/lib/ruby/gems/2.2.0/gems/fastlane-2.28.3/fastlane/lib/fastlane/configuration_helper.rb:4:in `parse'
from /Users/xxx/.fastlane/bin/bundle/lib/ruby/gems/2.2.0/gems/fastlane-2.28.3/fastlane/lib/fastlane/runner.rb:236:in `block (2 levels) in execute_action'
from /Users/xxx/.fastlane/bin/bundle/lib/ruby/gems/2.2.0/gems/fastlane-2.28.3/fastlane/lib/fastlane/actions/actions_helper.rb:50:in `execute_action'
from /Users/xxx/.fastlane/bin/bundle/lib/ruby/gems/2.2.0/gems/fastlane-2.28.3/fastlane/lib/fastlane/runner.rb:230:in `block in execute_action'
from /Users/xxx/.fastlane/bin/bundle/lib/ruby/gems/2.2.0/gems/fastlane-2.28.3/fastlane/lib/fastlane/runner.rb:226:in `chdir'
from /Users/xxx/.fastlane/bin/bundle/lib/ruby/gems/2.2.0/gems/fastlane-2.28.3/fastlane/lib/fastlane/runner.rb:226:in `execute_action'
from /Users/xxx/.fastlane/bin/bundle/lib/ruby/gems/2.2.0/gems/fastlane-2.28.3/fastlane/lib/fastlane/one_off.rb:41:in `run'
from /Users/xxx/.fastlane/bin/bundle/lib/ruby/gems/2.2.0/gems/fastlane-2.28.3/fastlane/lib/fastlane/one_off.rb:22:in `execute'
from /Users/xxx/.fastlane/bin/bundle/lib/ruby/gems/2.2.0/gems/fastlane-2.28.3/fastlane/lib/fastlane/commands_generator.rb:192:in `block (2 levels) in run'
from /Users/xxx/.fastlane/bin/bundle/lib/ruby/gems/2.2.0/gems/commander-fastlane-4.4.6/lib/commander/command.rb:178:in `call'
from /Users/xxx/.fastlane/bin/bundle/lib/ruby/gems/2.2.0/gems/commander-fastlane-4.4.6/lib/commander/command.rb:178:in `call'
from /Users/xxx/.fastlane/bin/bundle/lib/ruby/gems/2.2.0/gems/commander-fastlane-4.4.6/lib/commander/command.rb:153:in `run'
from /Users/xxx/.fastlane/bin/bundle/lib/ruby/gems/2.2.0/gems/commander-fastlane-4.4.6/lib/commander/runner.rb:476:in `run_active_command'
from /Users/xxx/.fastlane/bin/bundle/lib/ruby/gems/2.2.0/gems/fastlane-2.28.3/fastlane_core/lib/fastlane_core/ui/fastlane_runner.rb:40:in `run!'
from /Users/xxx/.fastlane/bin/bundle/lib/ruby/gems/2.2.0/gems/commander-fastlane-4.4.6/lib/commander/delegates.rb:15:in `run!'
from /Users/xxx/.fastlane/bin/bundle/lib/ruby/gems/2.2.0/gems/fastlane-2.28.3/fastlane/lib/fastlane/commands_generator.rb:303:in `run'
from /Users/xxx/.fastlane/bin/bundle/lib/ruby/gems/2.2.0/gems/fastlane-2.28.3/fastlane/lib/fastlane/commands_generator.rb:42:in `start'
from /Users/xxx/.fastlane/bin/bundle/lib/ruby/gems/2.2.0/gems/fastlane-2.28.3/fastlane/lib/fastlane/cli_tools_distributor.rb:66:in `take_off'
from /Users/xxx/.fastlane/bin/bundle/lib/ruby/gems/2.2.0/gems/fastlane-2.28.3/bin/fastlane:20:in `<top (required)>'
from /Users/xxx/.fastlane/bin/bundle/bin/fastlane:22:in `load'
from /Users/xxx/.fastlane/bin/bundle/bin/fastlane:22:in `<main>'

I'm so close! Any help would be appreciated.

HTTP Error: 403 - caller does not have permission

Hello,
I've been facing this error
Error: failed to fetch app information. HTTP Error: 403, The caller does not have permission

First I run this
export GOOGLE_APPLICATION_CREDENTIALS=/Users/my/..../android/secure/firebase-service-account-key.json

After I run this command from shell
fastlane run firebase_app_distribution app:y_app_id apk_path:./app/build/outputs/apk/release/app-release.apk

I follow this guide to create json key
https://firebase.google.com/docs/app-distribution/authenticate-service-account.md?platform=android

How can I solve it?
Where is my mistake?

Thank you
Claudio

Action 'firebase_app_distribution' not available, run `fastlane actions` to get a full list

❯ bundle exec fastlane run firebase_app_distribution
[βœ”] πŸš€ 
+------------------------------------+---------+----------------------------------------------------+
|                                           Used plugins                                            |
+------------------------------------+---------+----------------------------------------------------+
| Plugin                             | Version | Action                                             |
+------------------------------------+---------+----------------------------------------------------+
| fastlane-plugin-badge              | 1.1.0   | add_badge                                          |
| fastlane-plugin-versioning_android | 0.1.0   | android_get_version_name android_set_version_code  |
|                                    |         | android_set_version_name android_get_version_code  |
| fastlane-plugin-android_sdk_update | 1.0.0   | android_sdk_update                                 |
+------------------------------------+---------+----------------------------------------------------+


[!] Action 'firebase_app_distribution' not available, run `fastlane actions` to get a full list

I had no problems until 2 weeks ago. I could not find what affect it. does not appear in the list of "Used plugins" I can see the error with this command.

❯ bundle exec fastlane run firebase_app_distribution

I have this in fastlane/Pluginfile >>> gem 'fastlane-plugin-firebase_app_distribution'
and i can see the plugin in tmp-fastlane-ci-bundle/gems/fastlane-plugin-firebase_app_distribution

I have tried the following solutions

❯ sudo gem uninstall fastlane-plugin-firebase_app_distribution
❯ gem install fastlane-plugin-firebase_app_distribution --user-install

these doesn't work

❯ sudo chmod -R a+r /Library/Ruby/Gems/2.6.0/gems/fastlane-plugin-firebase_app_distribution-0.1.4
chmod: /Library/Ruby/Gems/2.6.0/gems/fastlane-plugin-firebase_app_distribution-0.1.4: No such file or directory

❯ bundle exec fassudo chmod -R a+r /Library/Ruby/Gems/2.6.0/gems/fastlane-plugin-firebase_app_distribution-0.1.4
bundler: command not found: fassudo
Install missing gem executables with `bundle install`

Error loading plugin 'fastlane-plugin-firebase_app_distribution': cannot load such file -- fastlane/plugin/firebase_app_distribution

Since installing the plugin, I've needed to root access to use fastlane. However, I can't do that because cocoapods cannot be run as root. Please advise.

Steps to reproduce

Run the build

  • bundle install
  • bundle exec fastlane qa

Output

Hinos-MacBook-Pro:ios hino$ bundle exec fastlane adhoc
[βœ”] πŸš€ 
[15:52:58]: Error loading plugin 'fastlane-plugin-firebase_app_distribution': cannot load such file -- fastlane/plugin/firebase_app_distribution
[15:52:58]: It seems like you wanted to load some plugins, however they couldn't be loaded
[15:52:58]: Please follow the troubleshooting guide: https://docs.fastlane.tools/plugins/plugins-troubleshooting/
....

My Environment

fastlane env

<details><summary>βœ… fastlane environment βœ…</summary>

### Stack

| Key                         | Value                                                          |
| --------------------------- | -------------------------------------------------------------- |
| OS                          | 10.15.3                                                        |
| Ruby                        | 2.6.3                                                          |
| Bundler?                    | false                                                          |
| Git                         | git version 2.21.1 (Apple Git-122.3)                           |
| Installation Source         | /usr/local/bin/fastlane                                        |
| Host                        | Mac OS X 10.15.3 (19D76)                                       |
| Ruby Lib Dir                | /System/Library/Frameworks/Ruby.framework/Versions/2.6/usr/lib |
| OpenSSL Version             | LibreSSL 2.8.3                                                 |
| Is contained                | false                                                          |
| Is homebrew                 | false                                                          |
| Is installed via Fabric.app | false                                                          |
| Xcode Path                  | /Applications/Xcode.app/Contents/Developer/                    |
| Xcode Version               | 11.3.1                                                         |


### System Locale

| Variable | Value       |   |
| -------- | ----------- | - |
| LANG     | en_US.UTF-8 | βœ… |
| LC_ALL   |             |   |
| LANGUAGE |             |   |


### fastlane files:

<details><summary>`./fastlane/Fastfile`</summary>

```ruby
# This file contains the fastlane.tools configuration
# You can find the documentation at https://docs.fastlane.tools
#
# For a list of all available actions, check out
#
#     https://docs.fastlane.tools/actions
#

# Uncomment the line if you want fastlane to automatically update itself
# update_fastlane

default_platform :ios

platform :ios do
  before_all do
    setup_circle_ci
  end

  desc "QA Build"
  lane :qa do
    cocoapods()
    match(type: "development", readonly: true)
    match(type: "adhoc", readonly: true)
    gym(export_method: "ad-hoc",
        workspace: "abc.xcworkspace",
        scheme: "abc-qa",
        clean: true)
  end

  desc "Upload AdHoc Build to App Distribution"
  lane :adhoc_distribute do
    firebase_app_distribution(app: "myFirebaseAppID",
                              ipa_path: "output/gym/abc.ipa",
                              groups: "group",
                              debug: true)
  end

end

`./fastlane/Appfile`
...

# For more information about the Appfile, see:
#     https://docs.fastlane.tools/advanced/#appfile

fastlane gems

Gem Version Update-Status
fastlane 2.144.0 βœ… Up-To-Date

Loaded fastlane plugins:

Plugin Version Update-Status
fastlane-plugin-firebase_app_distribution undefined πŸ’₯ Check failed
Loaded gems
Gem Version
did_you_mean 1.3.0
slack-notifier 2.3.2
rouge 2.0.7
xcpretty 0.3.0
terminal-notifier 2.0.0
terminal-table 1.8.0
plist 3.5.0
public_suffix 2.0.5
addressable 2.7.0
multipart-post 2.0.0
word_wrap 1.0.0
babosa 1.0.3
colored 1.2
highline 1.7.10
commander-fastlane 4.4.6
unf_ext 0.0.7.6
unf 0.1.4
domain_name 0.5.20190701
http-cookie 1.0.3
faraday-cookie_jar 0.0.6
faraday_middleware 0.13.1
fastimage 2.1.7
gh_inspector 1.1.3
multi_xml 0.6.0
rubyzip 1.3.0
security 0.1.3
xcpretty-travis-formatter 1.0.0
dotenv 2.7.5
bundler 2.0.2
jwt 2.1.0
uber 0.1.0
declarative 0.0.10
declarative-option 0.1.0
representable 3.0.4
retriable 3.1.2
mini_mime 1.0.2
httpclient 2.8.3
google-api-client 0.36.4
emoji_regex 1.0.1
jmespath 1.4.0
aws-eventstream 1.0.3
aws-sigv4 1.1.1
aws-sdk-core 3.92.0
aws-sdk-kms 1.30.0
aws-sdk-s3 1.61.1
nanaimo 0.2.6
colored2 3.1.2
claide 1.0.3
CFPropertyList 3.0.2
atomos 0.1.3
xcodeproj 1.15.0
unicode-display_width 1.7.0
tty-screen 0.7.1
tty-cursor 0.7.1
tty-spinner 0.9.3
excon 0.73.0
faraday 0.17.3
json 2.3.0
mini_magick 4.10.1
naturally 2.2.0
simctl 1.6.8
multi_json 1.14.1
signet 0.13.0
os 1.0.1
memoist 0.16.2
googleauth 0.11.0
digest-crc 0.5.1
google-cloud-errors 1.0.0
google-cloud-env 1.3.1
google-cloud-core 1.5.0
google-cloud-storage 1.25.1
aws-partitions 1.287.0
forwardable 1.2.0
logger 1.3.0
stringio 0.0.2
ipaddr 1.2.2
openssl 2.1.2
ostruct 0.1.0
strscan 1.0.0
date 2.0.0
fileutils 1.1.0
etc 1.0.1
io-console 0.4.7
zlib 1.0.0
libxml-ruby 3.1.0
rexml 3.1.9
psych 3.1.0
mutex_m 0.1.0
webrick 1.4.2
fastlane-plugin-firebase_app_distribution 0.1.4

generated on: 2020-03-26

```

iOS build and export is ok but only one file is on the distribution

While I have three different servers, I have to build three different apps with changed configuration
I tried to archive once and export the archive tree times with different configurations
As a result the file is uploaded and replaces the previous one
There is only DEV on the app distribution (Prod -> Test -> Dev)

I think there is an error with uploading in one lane. Should it be fixed or have I reimplement the logic?


β–Έ Archive Succeeded
Successfully stored the archive. You can find it in the Xcode Organizer.
-----------------
--- Step: act ---
-----------------
Patching Plist: Products/Applications/MyApp.app/Info.plist
----------------------------------
--- Step: get_info_plist_value ---
----------------------------------
-----------------
--- Step: act ---
-----------------
Patching Plist: Products/Applications/MyApp.app/Conf.plist
-----------------
--- Step: gym ---
-----------------
Successfully exported and compressed dSYM file
Successfully exported and signed the ipa file:
/MyApp/519/PROD/MyApp_PROD.ipa
----------------------------------
--- Step: get_info_plist_value ---
----------------------------------
---------------------------------------
--- Step: firebase_app_distribution ---
---------------------------------------
β–Έ i  getting app details...
β–Έ i  uploading distribution...
β–Έ βœ”  uploaded distribution successfully!
β–Έ i  adding release notes...
β–Έ βœ”  added release notes successfully
β–Έ i  adding testers/groups...
β–Έ βœ”  added testers/groups successfully
-----------------
--- Step: act ---
-----------------
Patching Plist: Products/Applications/MyApp.app/Conf.plist
-----------------
--- Step: gym ---
-----------------
Successfully exported and compressed dSYM file
Successfully exported and signed the ipa file:
/MyApp/519/TEST/MyApp_TEST.ipa
----------------------------------
--- Step: get_info_plist_value ---
----------------------------------
---------------------------------------
--- Step: firebase_app_distribution ---
---------------------------------------
β–Έ i  getting app details...
β–Έ i  uploading distribution...
β–Έ βœ”  uploaded distribution successfully!
β–Έ i  adding release notes...
β–Έ βœ”  added release notes successfully
β–Έ i  adding testers/groups...
β–Έ βœ”  added testers/groups successfully
-----------------
--- Step: act ---
-----------------
Patching Plist: Products/Applications/My.app/Conf.plist
-----------------
--- Step: gym ---
-----------------
Successfully exported and compressed dSYM file
Successfully exported and signed the ipa file:
/MyApp/519/DEV/MyApp_DEV.ipa
----------------------------------
--- Step: get_info_plist_value ---
----------------------------------
---------------------------------------
--- Step: firebase_app_distribution ---
---------------------------------------
β–Έ i  getting app details...
β–Έ i  uploading distribution...
β–Έ βœ”  uploaded distribution successfully!
β–Έ i  adding release notes...
β–Έ βœ”  added release notes successfully
β–Έ i  adding testers/groups...
β–Έ βœ”  added testers/groups successfully
--------------------------------------------------------------------
      
+------+--------------------------------------------+-------------+
|                        fastlane summary                         |
+------+--------------------------------------------+-------------+
| Step | Action                                     | Time (in s) |
+------+--------------------------------------------+-------------+
| 1    | default_platform                           | 0           |
| 2    | number_of_commits                          | 0           |
| 3    |                                            | 0           |
| 4    |                                            | 3           |
| 5    | gym                                        | 607         |
| 6    | act                                        | 0           |
| 7    | get_info_plist_value                       | 0           |
| 8    | act                                        | 0           |
| 9    | gym                                        | 64          |
| 10   | get_info_plist_value                       | 0           |
| 11   | firebase_app_distribution                  | 28          |
| 12   | act                                        | 0           |
| 13   | gym                                        | 57          |
| 14   | get_info_plist_value                       | 0           |
| 15   | firebase_app_distribution                  | 22          |
| 16   | act                                        | 0           |
| 17   | gym                                        | 56          |
| 18   | get_info_plist_value                       | 0           |
| 19   | firebase_app_distribution                  | 30          |
+------+--------------------------------------------+-------------+

fastlane.tools just saved you 15 minutes! πŸŽ‰

Fetch most recent version code from App Distribution

It would be nice if we could fetch the most recent version code from App Distribution so every time we upload a new APK we increment the version code based on the latest uploaded build.

The same feature as latest_testflight_build_number.

For iOS we can use this way:
increment_build_number(build_number: latest_testflight_build_number + 1)

Then for Android we could do this:
increment_version_code(version_code: latest_app_distribution_version_code + 1)

Firebase app distribution failing with unknown keyword: default_value_dynamic error

$ fastlane android distribute
+------------------------+---------+------------------------+
| Used plugins |
+------------------------+---------+------------------------+
| Plugin | Version | Action |
+------------------------+---------+------------------------+
| fastlane-plugin-fireb | 0.1.4 | firebase_app_distribu |
| ase_app_distribution | | tion |
+------------------------+---------+------------------------+

[18:03:29]: Your Fastfile has had smart quotes sanitised. To avoid issues in the future, you should not use TextEdit for editing it. If you are not using TextEdit, you should turn off smart quotes in your editor of choice.
[18:03:30]: -------------------------------------------------
[18:03:30]: --- Step: Verifying required fastlane version ---
[18:03:30]: -------------------------------------------------
[18:03:30]: Your fastlane version 2.28.3 matches the minimum requirement of 2.28.3 βœ…
[18:03:30]: ------------------------------
[18:03:30]: --- Step: default_platform ---
[18:03:30]: ------------------------------
[18:03:30]: Driving the lane 'android distribute' πŸš€
[18:03:30]: --------------------
[18:03:30]: --- Step: gradle ---
[18:03:30]: --------------------
[18:03:30]: $ /Users/sreekumarav/development/android-architecture-components/AndroidKoin/gradlew assembleDebug -p .
[18:03:30]: β–Έ > Task :app:preBuild UP-TO-DATE
[18:03:30]: β–Έ > Task :app:preDebugBuild UP-TO-DATE
[18:03:30]: β–Έ > Task :app:checkDebugManifest UP-TO-DATE
[18:03:30]: β–Έ > Task :app:generateDebugBuildConfig UP-TO-DATE
[18:03:30]: β–Έ > Task :app:compileDebugAidl NO-SOURCE
[18:03:30]: β–Έ > Task :app:compileDebugRenderscript NO-SOURCE
[18:03:30]: β–Έ > Task :app:mainApkListPersistenceDebug UP-TO-DATE
[18:03:30]: β–Έ > Task :app:generateDebugResValues UP-TO-DATE
[18:03:30]: β–Έ > Task :app:generateDebugResources UP-TO-DATE
[18:03:30]: β–Έ > Task :app:processDebugGoogleServices UP-TO-DATE
[18:03:30]: β–Έ > Task :app:mergeDebugResources UP-TO-DATE
[18:03:30]: β–Έ > Task :app:createDebugCompatibleScreenManifests UP-TO-DATE
[18:03:30]: β–Έ > Task :app:processDebugManifest UP-TO-DATE
[18:03:30]: β–Έ > Task :app:processDebugResources UP-TO-DATE
[18:03:30]: β–Έ > Task :app:compileDebugKotlin UP-TO-DATE
[18:03:30]: β–Έ > Task :app:javaPreCompileDebug UP-TO-DATE
[18:03:30]: β–Έ > Task :app:compileDebugJavaWithJavac UP-TO-DATE
[18:03:30]: β–Έ > Task :app:compileDebugSources UP-TO-DATE
[18:03:30]: β–Έ > Task :app:mergeDebugShaders UP-TO-DATE
[18:03:30]: β–Έ > Task :app:compileDebugShaders UP-TO-DATE
[18:03:30]: β–Έ > Task :app:generateDebugAssets UP-TO-DATE
[18:03:30]: β–Έ > Task :app:mergeDebugAssets UP-TO-DATE
[18:03:30]: β–Έ > Task :app:processDebugJavaRes NO-SOURCE
[18:03:30]: β–Έ > Task :app:mergeDebugJavaResource UP-TO-DATE
[18:03:30]: β–Έ > Task :app:transformClassesWithDexBuilderForDebug UP-TO-DATE
[18:03:30]: β–Έ > Task :app:checkDebugDuplicateClasses UP-TO-DATE
[18:03:30]: β–Έ > Task :app:mergeLibDexDebug UP-TO-DATE
[18:03:30]: β–Έ > Task :app:mergeExtDexDebug UP-TO-DATE
[18:03:30]: β–Έ > Task :app:mergeProjectDexDebug UP-TO-DATE
[18:03:30]: β–Έ > Task :app:validateSigningDebug UP-TO-DATE
[18:03:30]: β–Έ > Task :app:signingConfigWriterDebug UP-TO-DATE
[18:03:30]: β–Έ > Task :app:mergeDebugJniLibFolders UP-TO-DATE
[18:03:30]: β–Έ > Task :app:mergeDebugNativeLibs UP-TO-DATE
[18:03:30]: β–Έ > Task :app:stripDebugDebugSymbols UP-TO-DATE
[18:03:30]: β–Έ > Task :app:packageDebug UP-TO-DATE
[18:03:30]: β–Έ > Task :app:assembleDebug UP-TO-DATE
[18:03:30]: β–Έ BUILD SUCCESSFUL in 0s
[18:03:30]: β–Έ 27 actionable tasks: 27 up-to-date
[18:03:31]: Couldn't find any new signed apk files...
[18:03:31]: ---------------------------------------
[18:03:31]: --- Step: firebase_app_distribution ---
[18:03:31]: ---------------------------------------
[18:03:31]: You passed invalid parameters to 'firebase_app_distribution'.
[18:03:31]: Check out the error below and available options by running fastlane action firebase_app_distribution
+-----------------------------+--------------------+
| Lane Context |
+-----------------------------+--------------------+
| DEFAULT_PLATFORM | android |
| PLATFORM_NAME | android |
| LANE_NAME | android distribute |
| GRADLE_BUILD_TYPE | Debug |
| GRADLE_ALL_APK_OUTPUT_PATHS | [] |
+-----------------------------+--------------------+
[18:03:31]: unknown keyword: default_value_dynamic

+------+------------------------+-------------+
| fastlane summary |
+------+------------------------+-------------+
| Step | Action | Time (in s) |
+------+------------------------+-------------+
| 1 | Verifying required | 0 |
| | fastlane version | |
| 2 | default_platform | 0 |
| 3 | gradle | 1 |
| πŸ’₯ | firebase_app_distribu | 0 |
| | tion | |
+------+------------------------+-------------+

[18:03:31]: fastlane finished with errors

Looking for related GitHub issues on fastlane/fastlane...

Found no similar issues. To create a new issue, please visit:
https://github.com/fastlane/fastlane/issues/new
Run fastlane env to append the fastlane environment to your issue
/Users/sreekumarav/.fastlane/bin/bundle/lib/ruby/gems/2.2.0/gems/fastlane-2.28.3/fastlane_core/lib/fastlane_core/configuration/config_item.rb:58:in initialize': [!] unknown keyword: default_value_dynamic (ArgumentError) from /Users/sreekumarav/.fastlane/bin/bundle/lib/ruby/gems/2.2.0/gems/fastlane-plugin-firebase_app_distribution-0.1.4/lib/fastlane/plugin/firebase_app_distribution/actions/firebase_app_distribution_action.rb:65:in new'
from /Users/sreekumarav/.fastlane/bin/bundle/lib/ruby/gems/2.2.0/gems/fastlane-plugin-firebase_app_distribution-0.1.4/lib/fastlane/plugin/firebase_app_distribution/actions/firebase_app_distribution_action.rb:65:in available_options' from /Users/sreekumarav/.fastlane/bin/bundle/lib/ruby/gems/2.2.0/gems/fastlane-2.28.3/fastlane/lib/fastlane/configuration_helper.rb:4:in parse'
from /Users/sreekumarav/.fastlane/bin/bundle/lib/ruby/gems/2.2.0/gems/fastlane-2.28.3/fastlane/lib/fastlane/runner.rb:236:in block (2 levels) in execute_action' from /Users/sreekumarav/.fastlane/bin/bundle/lib/ruby/gems/2.2.0/gems/fastlane-2.28.3/fastlane/lib/fastlane/actions/actions_helper.rb:50:in execute_action'
from /Users/sreekumarav/.fastlane/bin/bundle/lib/ruby/gems/2.2.0/gems/fastlane-2.28.3/fastlane/lib/fastlane/runner.rb:230:in block in execute_action' from /Users/sreekumarav/.fastlane/bin/bundle/lib/ruby/gems/2.2.0/gems/fastlane-2.28.3/fastlane/lib/fastlane/runner.rb:226:in chdir'
from /Users/sreekumarav/.fastlane/bin/bundle/lib/ruby/gems/2.2.0/gems/fastlane-2.28.3/fastlane/lib/fastlane/runner.rb:226:in execute_action' from /Users/sreekumarav/.fastlane/bin/bundle/lib/ruby/gems/2.2.0/gems/fastlane-2.28.3/fastlane/lib/fastlane/runner.rb:148:in trigger_action_by_name'
from /Users/sreekumarav/.fastlane/bin/bundle/lib/ruby/gems/2.2.0/gems/fastlane-2.28.3/fastlane/lib/fastlane/fast_file.rb:146:in method_missing' from Fastfile:50:in block (2 levels) in parsing_binding'
from /Users/sreekumarav/.fastlane/bin/bundle/lib/ruby/gems/2.2.0/gems/fastlane-2.28.3/fastlane/lib/fastlane/lane.rb:33:in call' from /Users/sreekumarav/.fastlane/bin/bundle/lib/ruby/gems/2.2.0/gems/fastlane-2.28.3/fastlane/lib/fastlane/lane.rb:33:in call'
from /Users/sreekumarav/.fastlane/bin/bundle/lib/ruby/gems/2.2.0/gems/fastlane-2.28.3/fastlane/lib/fastlane/runner.rb:49:in block in execute' from /Users/sreekumarav/.fastlane/bin/bundle/lib/ruby/gems/2.2.0/gems/fastlane-2.28.3/fastlane/lib/fastlane/runner.rb:45:in chdir'
from /Users/sreekumarav/.fastlane/bin/bundle/lib/ruby/gems/2.2.0/gems/fastlane-2.28.3/fastlane/lib/fastlane/runner.rb:45:in execute' from /Users/sreekumarav/.fastlane/bin/bundle/lib/ruby/gems/2.2.0/gems/fastlane-2.28.3/fastlane/lib/fastlane/lane_manager.rb:52:in cruise_lane'
from /Users/sreekumarav/.fastlane/bin/bundle/lib/ruby/gems/2.2.0/gems/fastlane-2.28.3/fastlane/lib/fastlane/command_line_handler.rb:30:in handle' from /Users/sreekumarav/.fastlane/bin/bundle/lib/ruby/gems/2.2.0/gems/fastlane-2.28.3/fastlane/lib/fastlane/commands_generator.rb:104:in block (2 levels) in run'
from /Users/sreekumarav/.fastlane/bin/bundle/lib/ruby/gems/2.2.0/gems/commander-fastlane-4.4.6/lib/commander/command.rb:178:in call' from /Users/sreekumarav/.fastlane/bin/bundle/lib/ruby/gems/2.2.0/gems/commander-fastlane-4.4.6/lib/commander/command.rb:178:in call'
from /Users/sreekumarav/.fastlane/bin/bundle/lib/ruby/gems/2.2.0/gems/commander-fastlane-4.4.6/lib/commander/command.rb:153:in run' from /Users/sreekumarav/.fastlane/bin/bundle/lib/ruby/gems/2.2.0/gems/commander-fastlane-4.4.6/lib/commander/runner.rb:476:in run_active_command'
from /Users/sreekumarav/.fastlane/bin/bundle/lib/ruby/gems/2.2.0/gems/fastlane-2.28.3/fastlane_core/lib/fastlane_core/ui/fastlane_runner.rb:40:in run!' from /Users/sreekumarav/.fastlane/bin/bundle/lib/ruby/gems/2.2.0/gems/commander-fastlane-4.4.6/lib/commander/delegates.rb:15:in run!'
from /Users/sreekumarav/.fastlane/bin/bundle/lib/ruby/gems/2.2.0/gems/fastlane-2.28.3/fastlane/lib/fastlane/commands_generator.rb:303:in run' from /Users/sreekumarav/.fastlane/bin/bundle/lib/ruby/gems/2.2.0/gems/fastlane-2.28.3/fastlane/lib/fastlane/commands_generator.rb:42:in start'
from /Users/sreekumarav/.fastlane/bin/bundle/lib/ruby/gems/2.2.0/gems/fastlane-2.28.3/fastlane/lib/fastlane/cli_tools_distributor.rb:66:in take_off' from /Users/sreekumarav/.fastlane/bin/bundle/lib/ruby/gems/2.2.0/gems/fastlane-2.28.3/bin/fastlane:20:in <top (required)>'
from /Users/sreekumarav/.fastlane/bin/bundle/bin/fastlane:22:in load' from /Users/sreekumarav/.fastlane/bin/bundle/bin/fastlane:22:in

'

βœ… fastlane environment βœ…

Stack

Key Value
OS 10.14.6
Ruby 2.2.4
Bundler? false
Git git version 2.20.1 (Apple Git-117)
Installation Source ~/.fastlane/bin/bundle/bin/fastlane
Host Mac OS X 10.14.6 (18G95)
Ruby Lib Dir ~/.fastlane/bin/bundle/lib
OpenSSL Version OpenSSL 1.0.2g 1 Mar 2016
Is contained false
Is homebrew true
Is installed via Fabric.app false
Xcode Path /Applications/Xcode.app/Contents/Developer/
Xcode Version 10.3

System Locale

Variable Value
LANG en_US.UTF-8 βœ…
LC_ALL en_US.UTF-8 βœ…
LANGUAGE en_US.UTF-8 βœ…

fastlane files:

`./fastlane/Fastfile`
# Customise this file, documentation can be found here:
# https://github.com/fastlane/fastlane/tree/master/fastlane/docs
# All available actions: https://docs.fastlane.tools/actions
# can also be listed using the `fastlane actions` command

# Change the syntax highlighting to Ruby
# All lines starting with a # are ignored when running `fastlane`

# If you want to automatically update fastlane if a new version is available:
# update_fastlane

# This is the minimum version number required.
# Update this, if you use features of a newer version
fastlane_version "2.28.3"

default_platform :android

platform :android do
  before_all do
    # ENV["SLACK_URL"] = "https://hooks.slack.com/services/..."
  end

  desc "Runs all the tests"
  lane :test do
    gradle(task: "test")
  end

  desc "Submit a new Beta Build to Crashlytics Beta"
  lane :beta do
    gradle(task: "assembleRelease")
    crashlytics

    # sh "your_script.sh"
    # You can also use other beta testing services here
  end

  desc "Deploy a new version to the Google Play"
  lane :deploy do
    gradle(task: "assembleRelease")
    supply
  end

  desc "Deploying Debug build to firebase"
      lane :distribute do
        gradle(
            task: 'assemble',
            build_type: β€˜Debug’
          )

          firebase_app_distribution(
              app: "1:717023762309:android:1a7c9bca3ad336709656ec",
              release_notes: "Lots of amazing new features to test out!",
              firebase_cli_path: "/usr/local/bin/firebase"
          )

      end

  # You can define as many lanes as you want

  after_all do |lane|
    # This block is called, only if the executed lane was successful

    # slack(
    #   message: "Successfully deployed new App Update."
    # )
  end

  error do |lane, exception|
    # slack(
    #   message: exception.message,
    #   success: false
    # )
  end
end


# More information about multiple platforms in fastlane: https://github.com/fastlane/fastlane/blob/master/fastlane/docs/Platforms.md
# All available actions: https://docs.fastlane.tools/actions

# fastlane reports which actions are used
# No personal data is sent or shared. Learn more at https://github.com/fastlane/enhancer
`./fastlane/Appfile`
json_key_file "" # Path to the json secret file - Follow https://github.com/fastlane/supply#setup to get one
package_name "com.koin.sample" # e.g. com.krausefx.app

fastlane gems

Gem Version Update-Status
fastlane 2.28.3 πŸ’₯ Check failed

Loaded fastlane plugins:

Plugin Version Update-Status
fastlane-plugin-firebase_app_distribution 0.1.4 πŸ’₯ Check failed
Loaded gems
Gem Version
slack-notifier 1.5.1
atomos 0.1.3
CFPropertyList 2.3.5
claide 1.0.3
colored2 3.1.2
nanaimo 0.2.6
xcodeproj 1.12.0
rouge 2.0.7
xcpretty 0.3.0
terminal-notifier 1.7.1
unicode-display_width 1.1.3
terminal-table 1.7.3
plist 3.2.0
public_suffix 2.0.5
addressable 2.5.1
multipart-post 2.0.0
word_wrap 1.0.0
tty-screen 0.5.0
babosa 1.0.2
colored 1.2
highline 1.7.8
commander-fastlane 4.4.6
excon 0.55.0
faraday 0.12.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.1.3
uber 0.0.15
representable 2.3.0
retriable 2.1.0
mime-types-data 3.2016.0521
mime-types 3.1
hurley 0.2
little-plugger 1.1.4
multi_json 1.12.1
logging 2.2.2
jwt 1.5.6
memoist 0.16.0
os 0.9.6
signet 0.7.3
googleauth 0.5.1
httpclient 2.8.3
google-api-client 0.9.28
json 1.8.1
mini_magick 4.5.1
multi_xml 0.6.0
rubyzip 1.3.0
security 0.1.3
xcpretty-travis-formatter 0.0.4
dotenv 2.2.0
bundler 1.14.6
faraday_middleware 0.11.0.1
fastlane-plugin-firebase_app_distribution 0.1.4

generated on: 2019-10-13

Can someone help me with this?

Handle null app id

If user does not pass an app id to the acton, we try and find the apk/ipa within the current directory. If that fails, the app id is null and it fails. We should handle this scenario and display a useful error message.

Firebase failed upload

I got an error about uploading to Firebase:

 πŸ’₯   | firebase_app_distribution                        | 40          |
+------+--------------------------------------------------+-------------+

ERROR [2019-12-23 15:53:46.98]: fastlane finished with errors

Looking for related GitHub issues on fastlane/fastlane...
Search query: Shell command exited with exit status 1 instead of 0.
οΏ½]0;Firebase CLIοΏ½i  getting app details...
i  uploading distribution...

Error: failed to upload distribution. it took longer than expected to process your binary, please try again

URL: https://api.github.com/search/issues?q=Shell%20command%20exited%20with%20exit%20status%201%20instead%20of%200.%0A%1B%5D0%3BFirebase%20CLI%07%1B%5B1m%1B%5B36mi%20%1B%5B39m%1B%5B22m%20getting%20app%20details...%0A%1B%5B1m%1B%5B36mi%20%1B%5B39m%1B%5B22m%20uploading%20distribution...%0A%0A%1B%5B1m%1B%5B31mError%3A%1B%5B39m%1B%5B22m%20failed%20to%20upload%20distribution.%20it%20took%20longer%20than%20expected%20to%20process%20your%20binary%2C%20please%20try%20again%0A+repo:fastlane/fastlane
ERROR [2019-12-23 15:53:47.02]: Error finding relevant GitHub issues: undefined method `map' for nil:NilClass
bundler: failed to load command: fastlane (/home/circleci/repo/vendor/bundle/ruby/2.6.0/bin/fastlane)
FastlaneCore::Interface::FastlaneShellError: [!] Shell command exited with exit status 1 instead of 0.
οΏ½]0;Firebase CLIοΏ½i  getting app details...
i  uploading distribution...

Error: failed to upload distribution. it took longer than expected to process your binary, please try again

This issue is in CircleCI when I do parallel distribution for bulk of envs. Is it possible to change timeout or catch this error with try again e.g. for 2 or 3 times?
Or maybe it's an interaction limit in Firebase?

Stuck at the firebase_app_distribution step

Running my fastlane command in Android Studio terminal, I seem to be stuck in the 'Step : firebase_app_distribution' . However, the build is successfully uploaded into Firebase (I can see it in the console dashboard).

Below is my fastlane config :

lane :distribute do

  changelog = prompt(
    text: "Changelog: ",
    multi_line_end_keyword: "END"
  )

  # build the release variant
  build_android_app(
    task: 'assemble',
    build_type: β€˜Debug’,
    flavor: β€˜staging’
  )

  # upload to firebase app distribution
  firebase_app_distribution(
              app: "1:xxxxxxxxx:android:xxxxxxxxxxx",
              groups: "android",
              release_notes: changelog,
              firebase_cli_path: "/usr/local/bin/firebase"
          )
end

Using plugin generates duplicate builds on dashboard

I would like to ask if I am missing anything from my Fastfile setup as distributing to firebase app distribution using the plugin, it creates multiple entries for the same version/build while doing it manually it successfully replaces the previous one.

lane :qa_distribute do |release_notes|
  build_ios_app(
    scheme: "Stage",
    workspace: "MyProject.xcworkspace",
    output_directory: "./build/exports",
    export_options: {
      compileBitcode: false,
      method: "ad-hoc",
      iCloudContainerEnvironment: "Production"
    }
  )
  release_notes = changelog_from_git_commits(
    merge_commit_filtering: "exclude_merges"
  )
  firebase_distribution(notes: release_notes, groups: "qa-team")
  upload_symbols(token: ENV['CRASHLYTICS_API_KEY'])
end

private_lane :firebase_distribution do |options|
  firebase_app_distribution(
    app: ENV['FIREBASE_APP_ID'],
    release_notes: options[:notes] ? options[:notes] : "",
    groups: options[:groups],
    firebase_cli_path: "/usr/local/bin/firebase"
  )
end

firebase_cli_path:

Hi,

I am getting below error while trying to run through fastlane to distribute iOS app/

Error setting value '/usr/local/bin/firebase' for option 'firebase_cli_path'
[23:46:40]: You passed invalid parameters to 'firebase_app_distribution'.
[23:46:40]: Check out the error below and available options by running fastlane action firebase_app_distribution

I followed the steps provided in Firebase or researched in StackOverflow. I see the firebase path as firebase_cli_path: "/usr/local/bin/firebase" and it is the right location.

Get started button

Is there a way to not have to manually click the "Get started" button from the UI in order to submit the first beta of that app?

Screen Shot 2019-10-23 at 1 39 11 PM

Error 401 when running on CI

I'm trying to use the firebase app distribution on my CI platform, but I have a 404 error.

Firebase CLI version:
firebase-tools@οΏ½]0;Firebase CLIοΏ½8.4.0 is now installed

]0;Firebase CLIοΏ½[2020-05-22T23:55:20.036Z] > command requires scopes: ["email","openid","https://www.googleapis.com/auth/cloudplatformprojects.readonly","https://www.googleapis.com/auth/firebase","https://www.googleapis.com/auth/cloud-platform"]
[2020-05-22T23:55:20.037Z] > authorizing via --token option
i  getting app details... 
[2020-05-22T23:55:20.041Z] > refreshing access token with scopes: ["email","openid","https://www.googleapis.com/auth/cloudplatformprojects.readonly","https://www.googleapis.com/auth/firebase","https://www.googleapis.com/auth/cloud-platform"]
[2020-05-22T23:55:20.041Z] >>> HTTP REQUEST POST https://www.googleapis.com/oauth2/v3/token  
 <request body omitted>
[2020-05-22T23:55:20.158Z] <<< HTTP RESPONSE 401 {"content-type":"application/json; charset=utf-8","vary":"X-Origin, Referer, Origin,Accept-Encoding","date":"Fri, 22 May 2020 23:55:20 GMT","server":"scaffolding on HTTPServer2","cache-control":"private","x-xss-protection":"0","x-frame-options":"SAMEORIGIN","x-content-type-options":"nosniff","alt-svc":"h3-27=\":443\"; ma=2592000,h3-25=\":443\"; ma=2592000,h3-T050=\":443\"; ma=2592000,h3-Q050=\":443\"; ma=2592000,h3-Q049=\":443\"; ma=2592000,h3-Q048=\":443\"; ma=2592000,h3-Q046=\":443\"; ma=2592000,h3-Q043=\":443\"; ma=2592000,quic=\":443\"; ma=2592000; v=\"46,43\"","accept-ranges":"none","transfer-encoding":"chunked"}
[2020-05-22T23:55:20.160Z] >>> HTTP REQUEST GET https://firebaseappdistribution.googleapis.com/v1alpha/apps/[REDACTED] 
 
[2020-05-22T23:55:20.490Z] <<< HTTP RESPONSE 401 {"www-authenticate":"Bearer realm=\"https://accounts.google.com/\", error=\"invalid_token\"","vary":"X-Origin, Referer, Origin,Accept-Encoding","content-type":"application/json; charset=UTF-8","date":"Fri, 22 May 2020 23:55:20 GMT","server":"ESF","cache-control":"private","x-xss-protection":"0","x-frame-options":"SAMEORIGIN","x-content-type-options":"nosniff","alt-svc":"h3-27=\":443\"; ma=2592000,h3-25=\":443\"; ma=2592000,h3-T050=\":443\"; ma=2592000,h3-Q050=\":443\"; ma=2592000,h3-Q049=\":443\"; ma=2592000,h3-Q048=\":443\"; ma=2592000,h3-Q046=\":443\"; ma=2592000,h3-Q043=\":443\"; ma=2592000,quic=\":443\"; ma=2592000; v=\"46,43\"","accept-ranges":"none","transfer-encoding":"chunked"}
[2020-05-22T23:55:20.490Z] <<< HTTP RESPONSE BODY {"error":{"code":401,"message":"Request had invalid authentication credentials. Expected OAuth 2 access token, login cookie or other valid authentication credential. See https://developers.google.com/identity/sign-in/web/devconsole-project.","status":"UNAUTHENTICATED"}}

Error: failed to fetch app information. HTTP Error: 401, Request had invalid authentication credentials. Expected OAuth 2 access token, login cookie or other valid authentication credential. See https://developers.google.com/identity/sign-in/web/devconsole-project.

I tries putting my token in the ENV var FIREBASE_TOKEN, I tried to pass it as a parameter to the action, nothing works.

When I launch the exact same Fastfile with the exact same token locally, everything works fine.

What else can I try ?

Edit:
I even hard coded my token as a parameter to the action, I still have the exact same error.

[Feature request] Add a apk file name to the plugin configuration

TheΒ firebase_app_distribution fastlane plugin is picking up the most recent apk built - not the one the coordinated with the appId that has been set.

So when I had the uploads happening after all flavours had been built only the last apk was uploaded.Β 

For example:

Β  Β  buildApp(flavor: configAppDevelopFlavor, build_type: 'Release')
Β  Β  buildApp(flavor: configAppProductionFlavor, build_type: 'Release')

Β  Β  firebase_app_distribution(
      app: 'xxxx',
      groups: 'testers',
      firebase_cli_path: '/usr/local/bin/firebase',
      firebase_cli_token: 'zzzz',
      debug: true)

Β  Β  firebase_app_distribution(
      app: 'yyyy',
      groups: 'testers',
      firebase_cli_path: '/usr/local/bin/firebase',
      firebase_cli_token: 'zzzz',
      debug: true)

Results in 2 x 'App production' apps uploaded, one to each of the Firebase projects associated with those ids.Β 

When I changed it to:

Β  Β  buildApp(flavor: configAppDevelopFlavor, build_type: 'Release')
Β  Β  firebase_app_distribution(
      app: 'xxxx',
      groups: 'testers',
      firebase_cli_path: '/usr/local/bin/firebase',
      firebase_cli_token: 'zzzz',
      debug: true)

Β  Β  buildApp(flavor: configAppProductionFlavor, build_type: 'Release')
Β  Β  firebase_app_distribution(
      app: 'yyyy',
      groups: 'testers',
      firebase_cli_path: '/usr/local/bin/firebase',
      firebase_cli_token: 'zzzz',
      debug: true)

Each individual app was uploaded to the correct project on firebase.Β 

It would be useful to have a apk filename input to theΒ firebase_app_distribution fastlane plugin to make this clearer and allow customisation of build steps.

An unexpected error has occurred.

Hello, I'm trying to deploy an android app thru GitHub Actions my environment is:

Runs On: ubuntu-18-04
sudo npm install -g firebase-tools
sudo gem install bundler:1.16.5
sudo gem install fastlane -NV

And I'm running this command:

sudo fastlane deploy_to_firebase version:feature build:canary --verbose

This is the lane:

lane :deploy_to_firebase do |options|
    versionType = options[:version] || "qa"
    buildType = options[:build] || "canary
    version(type: versionType)
    build(type: buildType)
    deploy
end

lane :deploy do
     firebase_app_distribution(
         app: ENV['FIREBASE_ANDROID_APP_ID'],
         groups: "AndroidTeam",
         release_notes: "test",
         firebase_cli_path: "/usr/local/bin/firebase"
       )
end

And everything looks good in the pipeline until:

---------------------------------------
--- Step: firebase_app_distribution ---
---------------------------------------
β–Έ Error: An unexpected error has occurred.

Lane Context:
INFO - ***:PLATFORM_NAME=>nil,
:LANE_NAME=>"deploy_to_firebase",
:GRADLE_ALL_APK_OUTPUT_PATHS=>["/home/runner/work/xc60/xc60/app/build/outputs/apk/canary/app-canary.apk"***
:GRADLE_ALL_AAB_OUTPUT_PATHS=>[***
:GRADLE_ALL_OUTPUT_JSON_OUTPUT_PATHS=>["/home/runner/work/xc60/xc60/app/build/outputs/apk/canary/output.json"***
:GRADLE_ALL_MAPPING_TXT_OUTPUT_PATHS=>[***
:GRADLE_APK_OUTPUT_PATH=>"/home/runner/work/xc60/xc60/app/build/outputs/apk/canary/app-canary.apk",
:GRADLE_OUTPUT_JSON_OUTPUT_PATH=>"/home/runner/work/xc60/xc60/app/build/outputs/apk/canary/output.json"***
ERROR - Shell command exited with exit status 2 instead of 0.

+------+------------------------+-------------+
|              fastlane summary               |
+------+------------------------+-------------+
| Step | Action                 | Time (in s) |
+------+------------------------+-------------+
| 1    | Switch to version      | 0           |
|      | lane                   |             |
| 2    | -q prepareFeature      | 89          |
| 3    | Switch to build lane   | 0           |
| 4    | assembleCanary         | 293         |
| 5    | Switch to deploy lane  | 0           |
| πŸ’₯   | firebase_app_distribu  | 1           |
|      | tion                   |             |
+------+------------------------+-------------+

All plugins are up to date
ERROR - fastlane finished with errors

Looking for related GitHub issues on fastlane/fastlane...
Search query: Shell command exited with exit status 2 instead of 0.

Error: An unexpected error has occurred.

URL: https://api.github.com/search/issues?q=Shell%20command%20exited%20with%20exit%20status%202%20instead%20of%200.%0A%0A%1B%5B1m%1B%5B31mError%3A%1B%5B39m%1B%5B22m%20An%20unexpected%20error%20has%20occurred.%0A+repo:fastlane/fastlane
➑️  Possible to pass fastlane a .app or .zip?
    https://github.com/fastlane/fastlane/issues/330 [closed*** 2 πŸ’¬
    22 Sep 2016

➑️  s3 action failure after migrating to 1.3.0
    https://github.com/fastlane/fastlane/issues/318 [closed*** 6 πŸ’¬
/var/lib/gems/2.5.0/gems/fastlane-2.144.0/fastlane_core/lib/fastlane_core/ui/interface.rb:153:in `shell_error!': [!*** Shell command exited with exit status 2 instead of 0. (FastlaneCore::Interface::FastlaneShellError)

Error: An unexpected error has occurred.

	from /var/lib/gems/2.5.0/gems/fastlane-2.144.0/fastlane_core/lib/fastlane_core/ui/ui.rb:17:in `method_missing'
	from /var/lib/gems/2.5.0/gems/fastlane-2.144.0/fastlane/lib/fastlane/helper/sh_helper.rb:80:in `sh_control_output'
	from /var/lib/gems/2.5.0/gems/fastlane-plugin-firebase_app_distribution-0.1.4/lib/fastlane/plugin/firebase_app_distribution/actions/firebase_app_distribution_action.rb:29:in `run'
	from /var/lib/gems/2.5.0/gems/fastlane-2.144.0/fastlane/lib/fastlane/runner.rb:261:in `block (2 levels) in execute_action'
	from /var/lib/gems/2.5.0/gems/fastlane-2.144.0/fastlane/lib/fastlane/actions/actions_helper.rb:50:in `execute_action'
	from /var/lib/gems/2.5.0/gems/fastlane-2.144.0/fastlane/lib/fastlane/runner.rb:253:in `block in execute_action'
	from /var/lib/gems/2.5.0/gems/fastlane-2.144.0/fastlane/lib/fastlane/runner.rb:227:in `chdir'
	from /var/lib/gems/2.5.0/gems/fastlane-2.144.0/fastlane/lib/fastlane/runner.rb:227:in `execute_action'
	from /var/lib/gems/2.5.0/gems/fastlane-2.144.0/fastlane/lib/fastlane/runner.rb:157:in `trigger_action_by_name'
	from /var/lib/gems/2.5.0/gems/fastlane-2.144.0/fastlane/lib/fastlane/fast_file.rb:159:in `method_missing'
	from Fastfile:71:in `block in parsing_binding'
	from /var/lib/gems/2.5.0/gems/fastlane-2.144.0/fastlane/lib/fastlane/lane.rb:33:in `call'
	from /var/lib/gems/2.5.0/gems/fastlane-2.144.0/fastlane/lib/fastlane/runner.rb:204:in `try_switch_to_lane'
	from /var/lib/gems/2.5.0/gems/fastlane-2.144.0/fastlane/lib/fastlane/runner.rb:146:in `trigger_action_by_name'
	from /var/lib/gems/2.5.0/gems/fastlane-2.144.0/fastlane/lib/fastlane/fast_file.rb:159:in `method_missing'
	from Fastfile:48:in `block in parsing_binding'
	from /var/lib/gems/2.5.0/gems/fastlane-2.144.0/fastlane/lib/fastlane/lane.rb:33:in `call'
	from /var/lib/gems/2.5.0/gems/fastlane-2.144.0/fastlane/lib/fastlane/runner.rb:49:in `block in execute'
	from /var/lib/gems/2.5.0/gems/fastlane-2.144.0/fastlane/lib/fastlane/runner.rb:45:in `chdir'
	from /var/lib/gems/2.5.0/gems/fastlane-2.144.0/fastlane/lib/fastlane/runner.rb:45:in `execute'
	from /var/lib/gems/2.5.0/gems/fastlane-2.144.0/fastlane/lib/fastlane/lane_manager.rb:56:in `cruise_lane'
	from /var/lib/gems/2.5.0/gems/fastlane-2.144.0/fastlane/lib/fastlane/command_line_handler.rb:36:in `handle'
	from /var/lib/gems/2.5.0/gems/fastlane-2.144.0/fastlane/lib/fastlane/commands_generator.rb:108:in `block (2 levels) in run'
	from /var/lib/gems/2.5.0/gems/commander-fastlane-4.4.6/lib/commander/command.rb:178:in `call'
	from /var/lib/gems/2.5.0/gems/commander-fastlane-4.4.6/lib/commander/command.rb:153:in `run'
	from /var/lib/gems/2.5.0/gems/commander-fastlane-4.4.6/lib/commander/runner.rb:476:in `run_active_command'
	from /var/lib/gems/2.5.0/gems/fastlane-2.144.0/fastlane_core/lib/fastlane_core/ui/fastlane_runner.rb:76:in `run!'
	from /var/lib/gems/2.5.0/gems/commander-fastlane-4.4.6/lib/commander/delegates.rb:15:in `run!'
	from /var/lib/gems/2.5.0/gems/fastlane-2.144.0/fastlane/lib/fastlane/commands_generator.rb:349:in `run'
	from /var/lib/gems/2.5.0/gems/fastlane-2.144.0/fastlane/lib/fastlane/commands_generator.rb:41:in `start'
	from /var/lib/gems/2.5.0/gems/fastlane-2.144.0/fastlane/lib/fastlane/cli_tools_distributor.rb:119:in `take_off'
	from /var/lib/gems/2.5.0/gems/fastlane-2.144.0/bin/fastlane:23:in `<top (required)>'
	from /usr/local/bin/fastlane:23:in `load'
	from /usr/local/bin/fastlane:23:in `<main>'
    22 Sep 2016

➑️  Trouble using fastlane / sigh on multi-user system
    https://github.com/fastlane/fastlane/issues/326 [closed*** 13 πŸ’¬
    08 Nov 2016

and 16126 more at: https://github.com/fastlane/fastlane/search?q=Shell%20command%20exited%20with%20exit%20status%202%20instead%20of%200.%0A%0A%1B%5B1m%1B%5B31mError%3A%1B%5B39m%1B%5B22m%20An%20unexpected%20error%20has%20occurred.%0A&type=Issues&utf8=βœ“

DEBUG [2020-04-03 17:47:42.93***: All plugins are up to date
##[error***Process completed with exit code 1.

Any idea what could be happening? I ran this with --verbose but it didn't change at all.

iOS build succeeds but ipa file does not seem to be accessible from Firebase

I have an iOS build that I am running with CircleCI with the intention for it to be distributed to testers via Firebase.

The build succeeds and I get confirmation the ipa has been uploaded to FIrebase, the specified tester(s) get an email notification, but when they try to access the app they simply get a message saying there is no app.

The Firebase console on my end updates with a distribution and the tester information, but from what I can tell there there does not seem to be any ipa attached to the distribution.

I have ssh'd into the passing Circle build to ensure the ipa is created, and have downloaded it manually.

Please see below my Fastfile, config.yml and build log, is there something I am missing?

Fastfile:

platform :ios do
  before_all do
    setup_circle_ci
  end

  lane :beta do
    match(
      type: "appstore",
      team_id: TEAM,
      app_identifier: APP_ID,
      output_path: "./builds",
      keychain_name: "fastlane_tmp_keychain",
      readonly: is_ci
    )
    settings_to_override = {
      :BUNDLE_IDENTIFIER => APP_ID,
      :PROVISIONING_PROFILE_SPECIFIER => PROFILE,
      :DEVELOPMENT_TEAM => TEAM
    }
    update_project_team( 
      teamid: CredentialsManager::AppfileConfig.try_fetch_value(:team_id)
    )
    increment_build_number(xcodeproj: "MyApp.xcodeproj")
    build_app(
      clean: true,
      export_method: "app-store",
      build_path: "./builds",
      output_directory: "./builds",
      xcargs: settings_to_override,
      scheme: "My app",
      export_options: {
        signingCertificate: SIGNING_CERTIFICATE,
        provisioningProfiles: {
          APP_ID => PROFILE
        }
      }
    )
    firebase_app_distribution(
      app: FIREBASE_APP_ID,
      testers: TESTER,
      release_notes: "New updates to test",
      ipa_path: "/Users/distiller/repo/ios/builds/myIpa.ipa",
      firebase_cli_path: "/Users/distiller/repo/node_modules/.bin/firebase"
    )
  end
end

Circle config:

version: 2
jobs:
    build:
        macos:
            xcode: '10.3.0'

        working_directory: ~/repo
        environment:
            FASTLANE_LANE: beta

        steps:
            - checkout
            - run:
                  # We can't set this using an image because that makes the build run in a Linux box
                  name: 'Manually set ruby version to 2.6.3'
                  command: echo "ruby-2.6.3" > ~/.ruby-version
            - run:
                  name: install bundler
                  command: gem install bundler --version 2.0.1
            - run: cd ./ios && bundle install
            - run:
                  # This is necessary to ensure that native modules will compile properly
                  name: 'Install specific Node and NPM versions'
                  command: |
                      curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.35.1/install.sh | bash
                        echo 'export NVM_DIR="$HOME/.nvm"' >> $BASH_ENV
                        echo '[ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh"' >> $BASH_ENV
                        echo 'nvm install v10.17.0' >> $BASH_ENV
                        echo 'nvm alias default v10.17.0' >> $BASH_ENV
            - run:
                  name: 'Install JS dependencies and run post-install steps'
                  command: npm install
            - run:
                  name: Fastlane
                  command: cd ./ios && bundle exec fastlane $FASTLANE_LANE

Circle build passing:

[09:41:51]: Successfully exported and compressed dSYM file
[09:41:51]: Successfully exported and signed the ipa file:
[09:41:51]: /Users/distiller/repo/ios/builds/Converge.ipa
[09:41:51]: ---------------------------------------
[09:41:51]: --- Step: firebase_app_distribution ---
[09:41:51]: ---------------------------------------
[09:41:56]: β–Έ i  getting app details...
[09:41:57]: β–Έ i  uploading distribution...
[09:42:10]: β–Έ βœ”  uploaded distribution successfully
[09:42:10]: β–Έ i  adding release notes...
[09:42:11]: β–Έ βœ”  added release notes successfully
[09:42:11]: β–Έ i  adding testers/groups...
[09:42:11]: β–Έ βœ”  added testers/groups successfully

+------+---------------------------+-------------+
|                fastlane summary                |
+------+---------------------------+-------------+
| Step | Action                    | Time (in s) |
+------+---------------------------+-------------+
| 1    | default_platform          | 0           |
| 2    | setup_circle_ci           | 0           |
| 3    | is_ci                     | 0           |
| 4    | match                     | 2           |
| 5    | update_project_team       | 0           |
| 6    | increment_build_number    | 2           |
| 7    | build_app                 | 654         |
| 8    | firebase_app_distribution | 20          |
+------+---------------------------+-------------+

Using Service Account Credentials

According to official documentation, there is a way to sign in with a service account.

https://firebase.google.com/docs/app-distribution/ios/distribute-fastlane

Note: If you're using fastlane in a CI environment, you can also sign in with a service account or by using login:ci.

But looking into plugin documentation or the login instructions in the CLI, there's absolutely no way to specify the service account credentials JSON file.

Am I missing something or is this just a mistake in docs?

You passed invalid parameters to 'firebase_app_distribution'.

So I have installed the firebase binary, I logged in and have access to my projects. I installed the plugin and the relevant part of my Fastfile looks like this:

firebasePath = sh("which firebase")
firebaseDirectory = sh("dirname #{firebasePath}")
firebase_app_distribution(
        app: "1:642144225493:ios:1585402b689cc482",
        firebase_cli_path: "#{firebaseDirectory}")

The which firebase command resolves to /usr/local/bin/firebase so I can see the following errors when trying to execute this step:

[08:54:43]: Error setting value '/usr/local/bin/firebase
' for option 'firebase_cli_path'
[08:54:43]: You passed invalid parameters to 'firebase_app_distribution'.
[08:54:43]: Check out the error below and available options by running `fastlane action firebase_app_distribution`

[08:54:43]: firebase_cli_path: missing path to firebase cli tool. Please install firebase in $PATH or specify path

Ideas?

[0.1.4] No actions found in Plugin version.

Hi! Looks like when installing plugins, no actions are found in the latest version (0.1.4 at the time of writing) of firebase_app_distribution.

Fixing version to 0.1.2:

image

With version 0.1.4:

image

Handle missing app id

In v0.2.0 we get this error when the app param is nil:

$ bundle exec fastlane run firebase_app_distribution
[βœ”] πŸš€ 
+-------------------------------------------+---------+-----------------------------------------------------------+
|                                                  Used plugins                                                   |
+-------------------------------------------+---------+-----------------------------------------------------------+
| Plugin                                    | Version | Action                                                    |
+-------------------------------------------+---------+-----------------------------------------------------------+
| fastlane-plugin-firebase_app_distribution | 0.1.4   | firebase_app_distribution_login firebase_app_distribution |
+-------------------------------------------+---------+-----------------------------------------------------------+

[18:02:55]: ---------------------------------------
[18:02:55]: --- Step: firebase_app_distribution ---
[18:02:55]: ---------------------------------------

...

bundler: failed to load command: fastlane (/usr/local/google/home/alonsosi/.rbenv/versions/2.5.8/bin/fastlane)
NoMethodError: [!] undefined method `status' for nil:NilClass
  /usr/local/google/home/alonsosi/Desktop/fastlane-plugin-firebase_app_distribution/lib/fastlane/plugin/firebase_app_distribution/actions/firebase_app_distribution_action.rb:209:in `rescue in get_app'
  /usr/local/google/home/alonsosi/Desktop/fastlane-plugin-firebase_app_distribution/lib/fastlane/plugin/firebase_app_distribution/actions/firebase_app_distribution_action.rb:182:in `get_app'
  /usr/local/google/home/alonsosi/Desktop/fastlane-plugin-firebase_app_distribution/lib/fastlane/plugin/firebase_app_distribution/actions/firebase_app_distribution_action.rb:22:in `run'

...

We should handle this scenario by asking the user for the app id, which is the way the current plugin handles it:

$bundle exec fastlane run firebase_app_distribution
[βœ”] πŸš€
+-------------------------------------------+---------+---------------------------+
|                                  Used plugins                                   |
+-------------------------------------------+---------+---------------------------+
| Plugin                                    | Version | Action                    |
+-------------------------------------------+---------+---------------------------+
| fastlane-plugin-firebase_app_distribution | 0.1.4   | firebase_app_distribution |
+-------------------------------------------+---------+---------------------------+

[13:58:56]: ---------------------------------------
[13:58:56]: --- Step: firebase_app_distribution ---
[13:58:56]: ---------------------------------------
[13:58:56]: To not be asked about this value, you can specify it using 'app'
[13:58:56]: Your app's Firebase App ID. You can find the App ID in the Firebase console, on the General Settings page:

Metric collection.

Add in metric headers when the binary is uploaded.

As well as adding in release version to the metrics.

Error: Implementing `is_supported?` for all actions is mandatory. Please update Fastlane::Actions::FirebaseAppDistributionAction (FastlaneCore::Interface::FastlaneCrash)

I'm getting this error while trying to run fastlane distribute group:only-me. Looks like there may be a missing method implemented in the plugin?

        25: from C:/Ruby26-x64/bin/fastlane:23:in `<main>'
        24: from C:/Ruby26-x64/bin/fastlane:23:in `load'
        23: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/fastlane-2.143.0/bin/fastlane:23:in `<top (required)>'
        22: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/fastlane-2.143.0/fastlane/lib/fastlane/cli_tools_distributor.rb:119:in `take_off'
        21: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/fastlane-2.143.0/fastlane/lib/fastlane/commands_generator.rb:41:in `start'
        20: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/fastlane-2.143.0/fastlane/lib/fastlane/commands_generator.rb:349:in `run'
        19: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/commander-fastlane-4.4.6/lib/commander/delegates.rb:15:in `run!'
        18: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/fastlane-2.143.0/fastlane_core/lib/fastlane_core/ui/fastlane_runner.rb:76:in `run!'
        17: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/commander-fastlane-4.4.6/lib/commander/runner.rb:476:in `run_active_command'
        16: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/commander-fastlane-4.4.6/lib/commander/command.rb:153:in `run'
        15: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/commander-fastlane-4.4.6/lib/commander/command.rb:178:in `call'
        14: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/fastlane-2.143.0/fastlane/lib/fastlane/commands_generator.rb:108:in `block (2 levels) in run'
        13: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/fastlane-2.143.0/fastlane/lib/fastlane/command_line_handler.rb:36:in `handle'
        12: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/fastlane-2.143.0/fastlane/lib/fastlane/lane_manager.rb:56:in `cruise_lane'
        11: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/fastlane-2.143.0/fastlane/lib/fastlane/runner.rb:45:in `execute'
        10: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/fastlane-2.143.0/fastlane/lib/fastlane/runner.rb:45:in `chdir'
         9: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/fastlane-2.143.0/fastlane/lib/fastlane/runner.rb:49:in `block in execute'
         8: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/fastlane-2.143.0/fastlane/lib/fastlane/lane.rb:33:in `call'
         7: from Fastfile:25:in `block (2 levels) in parsing_binding'
         6: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/fastlane-2.143.0/fastlane/lib/fastlane/fast_file.rb:159:in `method_missing'
         5: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/fastlane-2.143.0/fastlane/lib/fastlane/runner.rb:157:in `trigger_action_by_name'
         4: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/fastlane-2.143.0/fastlane/lib/fastlane/runner.rb:224:in `execute_action'
         3: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/fastlane-2.143.0/fastlane/lib/fastlane/runner.rb:298:in `verify_supported_os'
         2: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/fastlane-2.143.0/fastlane/lib/fastlane/action.rb:103:in `is_supported?'
         1: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/fastlane-2.143.0/fastlane_core/lib/fastlane_core/ui/ui.rb:17:in `method_missing'
C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/fastlane-2.143.0/fastlane_core/lib/fastlane_core/ui/interface.rb:129:in `crash!': Implementing `is_supported?` for all actions is mandatory. Please update Fastlane::Actions::FirebaseAppDistributionAction (FastlaneCore::Interface::FastlaneCrash)
        25: from C:/Ruby26-x64/bin/fastlane:23:in `<main>'
        24: from C:/Ruby26-x64/bin/fastlane:23:in `load'
        23: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/fastlane-2.143.0/bin/fastlane:23:in `<top (required)>'
        22: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/fastlane-2.143.0/fastlane/lib/fastlane/cli_tools_distributor.rb:119:in `take_off'
        21: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/fastlane-2.143.0/fastlane/lib/fastlane/commands_generator.rb:41:in `start'
        20: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/fastlane-2.143.0/fastlane/lib/fastlane/commands_generator.rb:349:in `run'
        19: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/commander-fastlane-4.4.6/lib/commander/delegates.rb:15:in `run!'
        18: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/fastlane-2.143.0/fastlane_core/lib/fastlane_core/ui/fastlane_runner.rb:76:in `run!'
        17: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/commander-fastlane-4.4.6/lib/commander/runner.rb:476:in `run_active_command'
        16: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/commander-fastlane-4.4.6/lib/commander/command.rb:153:in `run'
        15: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/commander-fastlane-4.4.6/lib/commander/command.rb:178:in `call'
        14: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/fastlane-2.143.0/fastlane/lib/fastlane/commands_generator.rb:108:in `block (2 levels) in run'
        13: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/fastlane-2.143.0/fastlane/lib/fastlane/command_line_handler.rb:36:in `handle'
        12: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/fastlane-2.143.0/fastlane/lib/fastlane/lane_manager.rb:56:in `cruise_lane'
        11: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/fastlane-2.143.0/fastlane/lib/fastlane/runner.rb:45:in `execute'
        10: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/fastlane-2.143.0/fastlane/lib/fastlane/runner.rb:45:in `chdir'
         9: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/fastlane-2.143.0/fastlane/lib/fastlane/runner.rb:49:in `block in execute'
         8: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/fastlane-2.143.0/fastlane/lib/fastlane/lane.rb:33:in `call'
         7: from Fastfile:25:in `block (2 levels) in parsing_binding'
         6: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/fastlane-2.143.0/fastlane/lib/fastlane/fast_file.rb:159:in `method_missing'
         5: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/fastlane-2.143.0/fastlane/lib/fastlane/runner.rb:157:in `trigger_action_by_name'
         4: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/fastlane-2.143.0/fastlane/lib/fastlane/runner.rb:224:in `execute_action'
         3: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/fastlane-2.143.0/fastlane/lib/fastlane/runner.rb:298:in `verify_supported_os'
         2: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/fastlane-2.143.0/fastlane/lib/fastlane/action.rb:103:in `is_supported?'
         1: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/fastlane-2.143.0/fastlane_core/lib/fastlane_core/ui/ui.rb:17:in `method_missing'
C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/fastlane-2.143.0/fastlane_core/lib/fastlane_core/ui/interface.rb:129:in `crash!': [!] Implementing `is_supported?` for all actions is mandatory. Please update Fastlane::Actions::FirebaseAppDistributionAction (FastlaneCore::Interface::FastlaneCrash)```

Proposal: return direct link for download

Is it possible to return direct for downloading uploaded build?
I mean that it would be very easy to have direct link integrated with Jira or smth else to download certain build for certain PR in case of CI/CD

Support for AAB

Hi

Thanks for this awesome plugin, it worked really easy the first time I tried.

Currently the plugin just support this property apk_path.

It will be cool if you can add support for AAB (app bundles), so the testers can test the real apk based on it's device, see installed app size and those kind of things that will vary if you use AAB instead of APK.

How to handle Android multiple APKs (split per arch)

Android allow to split my app per CPU arch into multiple APKs to submit smaller app to store.
There is a way to push to firebase all generated APKs ?
If don't specify apk_path option, this plugin use the first apk found.
I don't know how to specify multiple path on apk_path. Is it possible ?

Errors when building on Jenkins (with Service Account)

I get the error Invalid default value for firebase_cli_path, doesn't match verify_block when building on jenkins. I understand this is because I did not pass a firebase_cli_path as a param.
However, I can see that from the docs you can use service-accounts and set an env variable GOOGLE_APPLICATION_CREDENTIALS as the path to the service account's file, all of which I have done.
Any idea how/if this plugin uses service-accounts?

fastlane-plugin-firebase_app_distribution: 0.1.4

how to distribute aab file

i would like to distribute app bundle through this plugin but i can't.
i explored this document, it does not have such a function.
does it have this way?
or do you have a plan it will be implemented?

Include Firebase Binary In Gem

Hello!

Thanks for making this plugin to Fastlane. I'm kind of curious to know why the actual firebase binary is not included in this gem. I understand that the instructions clearly list downloading the binary as a standalone executable, or doing it via NPM.

I'd like to better understand the motivation of packaging this as an NPM set of tools (rather than including the full set in Ruby), and if PRs would be welcome that included this binary by default so people would not have to manage additional dependencies (standalone or other dependency systems such as NPM) on local or Continuous Integration systems.

Thanks!

Update Docs

Talking to Bonnie about what docs to update.

Fails if path firebase_cli_path contains spaces

It's impossible to run firebase_app_distribution action if the value passed to firebase_cli_path contains spaces. Failure happens on Actions.sh_control_output.

I tried to shellescape the string before passing to action, but in this case the verify_block fails.

It only begins to work if I shellescape the path by changing the following line

cmd = [params[:firebase_cli_path].chomp, FIREBASECMD_ACTION]

to

cmd = [params[:firebase_cli_path].chomp.shellescape, FIREBASECMD_ACTION]

[0.1.4] No actions found in Plugin version on Windows

Hi. I'm trying to use firebase_app_distribution on my Fastfile.
I followed the tutorial of Firebase website: firebase_app_distribution tutorial link.
When I run the simple command fastlane, when it is installing the plugin 'firebase_app_distribution', no Actions are found.

I did exactly the same thing above on Mac OS and it works with no errors.

I also read the thread: [0.1.4] No actions found in Plugin version. and tried each of the suggestions and nothing worked on Windows (including use 0.1.2 version of the plugin).

OS: Windows Server 2016
Versions:
Fastlane: 2.143.0
Ruby: 2.7.0

Follow part of the Log

[11:23:01]: Error loading plugin 'fastlane-plugin-firebase_app_distribution': No such file or directory - which firebase

[11:23:01]: It seems like you wanted to load some plugins, however they couldn't be loaded
[11:23:01]: Please follow the troubleshooting guide: https://docs.fastlane.tools/plugins/plugins-troubleshooting/
+-------------------------------------------+---------+------------------+
| Used plugins |
+-------------------------------------------+---------+------------------+
| Plugin | Version | Action |
+-------------------------------------------+---------+------------------+
| fastlane-plugin-firebase_app_distribution | 0.1.4 | No actions found |
+-------------------------------------------+---------+------------------+

[!] No actions were found while loading one or more plugins
Please use bundle exec fastlane with plugins
More info - https://docs.fastlane.tools/plugins/using-plugins/#run-with-plugins

C:/tools/ruby27/lib/ruby/gems/2.7.0/gems/fastlane-2.143.0/fastlane/lib/fastlane/plugins/plugin_manager.rb:162: warning: calling URI.open via Kernel#open is deprecated, call URI.open directly or use URI#open
C:/tools/ruby27/lib/ruby/gems/2.7.0/gems/fastlane-2.143.0/fastlane_core/lib/fastlane_core/ui/interface.rb:141: warning: Using the last argument as keyword parameters is deprecated; maybe ** should be added to the call
C:/tools/ruby27/lib/ruby/gems/2.7.0/gems/fastlane-2.143.0/fastlane_core/lib/fastlane_core/ui/errors/fastlane_error.rb:9: warning: The called method `initialize' is defined here

firebase_app_distribution fails with relative paths

I got error.
1 with Error: Command requires authentication, please run firebase login
that's why firebase_app_distribution doesn't find the file in GOOGLE_APPLICATION_CREDENTIALS

My lane include this script

desc "Deploy to Crashlytics"
	lane :deploy_to_crashlytics do
		sh ("echo $PWD");
		sh ("echo $GOOGLE_APPLICATION_CREDENTIALS");
		firebase_app_distribution(
			app: ENV["FIREBASE_APP_ID"],
			apk_path: "../app/build/outputs/apk/release/app-release.apk",
			groups: "internal-android, internal-ios"
		)
	end

My current folder, when lane is running, (echo $PWD) is
Users/claudio/Desktop/LAB/MyProject/MyApp/android/fastlane

My file are in
/Users/claudio/Desktop/LAB/MyProject/MyApp/android/secure/service-account-key.json

Any suggestions?

Thanks again

Firebase distribution fails when triggered from GitHub hook

Hi there,

I hope you can help me out as I'm observing something odd yet frustrating πŸ˜“
I have implemented successfully the firebase plugin and managed to make it work both locally and on the CI (I'm using Bitrise).
However, when a Bitrise build is triggered from a hook when pushing on my remote Git branch the firebase_app_distribution fails right away although it succeeds when triggered manually on the CI (for the same workflow!)

Capture d’écran 2020-02-21 aΜ€ 11 47 34

The workflow is the same and I do nothing else in the lane that is invoking the firebase_app_distribution task. I've added lots of prints and it fails as soon as it hits the firebase_app_distribution method.

Here is the successful build

+-------------------------------------------+---------+---------------------------+
|                                  Used plugins                                   |
+-------------------------------------------+---------+---------------------------+
| Plugin                                    | Version | Action                    |
+-------------------------------------------+---------+---------------------------+
| fastlane-plugin-teams                     | 0.2.0   | teams                     |
| fastlane-plugin-firebase_app_distribution | 0.1.4   | firebase_app_distribution |
+-------------------------------------------+---------+---------------------------+
[09:12:23]: ----------------------------------------
[09:12:23]: --- Step: Verifying fastlane version ---
[09:12:23]: ----------------------------------------
[09:12:23]: Your fastlane version 2.142.0 matches the minimum requirement of 2.134.0  βœ…
[09:12:23]: ------------------------------
[09:12:23]: --- Step: default_platform ---
[09:12:23]: ------------------------------
[09:12:23]: Driving the lane 'android beta' πŸš€
/usr/local/lib/ruby/gems/2.7.0/gems/fastlane-2.142.0/fastlane/lib/fastlane/plugins/plugin_manager.rb:162: warning: calling URI.open via Kernel#open is deprecated, call URI.open directly or use URI#open
[09:12:25]: ---------------------------------------
[09:12:25]: --- Step: firebase_app_distribution ---
[09:12:25]: ---------------------------------------
[09:12:26]: β–Έ i  getting app details...
[09:12:27]: β–Έ i  uploading distribution...
[09:12:33]: β–Έ βœ”  uploaded distribution successfully!
[09:12:33]: β–Έ ⚠  no release notes specified, skipping
[09:12:33]: β–Έ i  adding testers/groups...
[09:12:34]: β–Έ βœ”  added testers/groups successfully

And the failed one that is of interest

+-------------------------------------------+---------+---------------------------+
|                                  Used plugins                                   |
+-------------------------------------------+---------+---------------------------+
| Plugin                                    | Version | Action                    |
+-------------------------------------------+---------+---------------------------+
| fastlane-plugin-teams                     | 0.2.0   | teams                     |
| fastlane-plugin-firebase_app_distribution | 0.1.4   | firebase_app_distribution |
+-------------------------------------------+---------+---------------------------+
[09:42:19]: ----------------------------------------
[09:42:19]: --- Step: Verifying fastlane version ---
[09:42:19]: ----------------------------------------
[09:42:19]: Your fastlane version 2.142.0 matches the minimum requirement of 2.134.0  βœ…
[09:42:19]: ------------------------------
[09:42:19]: --- Step: default_platform ---
[09:42:19]: ------------------------------
[09:42:19]: Driving the lane 'android beta' πŸš€
[09:42:19]: Begin firebase upload #<Fastlane::FastFile::Project:0x00005618f2529b60>
/usr/local/lib/ruby/gems/2.7.0/gems/fastlane-2.142.0/fastlane/lib/fastlane/plugins/plugin_manager.rb:162: warning: calling URI.open via Kernel#open is deprecated, call URI.open directly or use URI#open
[09:42:22]: ---------------------------------------
[09:42:22]: --- Step: firebase_app_distribution ---
[09:42:22]: ---------------------------------------
[09:42:24]: β–Έ Error: An unexpected error has occurred.
[09:42:24]: Shell command exited with exit status 2 instead of 0.
Error: An unexpected error has occurred.
+------------------+--------------+
|          Lane Context           |
+------------------+--------------+
| DEFAULT_PLATFORM | android      |
| PLATFORM_NAME    | android      |
| LANE_NAME        | android beta |
+------------------+--------------+
[09:42:24]: Shell command exited with exit status 2 instead of 0.
Error: An unexpected error has occurred.
+------+----------------------------+-------------+
|                fastlane summary                 |
+------+----------------------------+-------------+
| Step | Action                     | Time (in s) |
+------+----------------------------+-------------+
| 1    | Verifying fastlane version | 0           |
| 2    | default_platform           | 0           |
| πŸ’₯   | firebase_app_distribution  | 2           |
+------+----------------------------+-------------+
[09:42:24]: fastlane finished with errors

Any help would be much appreciated πŸ™

DSYM upload handling?

Does an invocation of firebase_app_distribution upload DSYMs as well?
I can't find a clear answer in the docs.

Filed to upload distribution. HTTP Error: 413. Unknown Error

So, I am trying to upload a binary to Firebase using Firebase_App_Distribution plugin on Fastlane.

It seems a HTTP 413 error occurs. According to standard error codes 413 stands for "Payload Too Large". So maybe there is any kind of size limitation on the binary.

Note I am trying to upload an ipa about 1.12GB (xcarchive 2.09GB). See error message below:

[15:05:04]: ---------------------------------------
[15:05:04]: --- Step: firebase_app_distribution ---
[15:05:04]: ---------------------------------------
[15:05:05]: β–Έ i  getting app details...
[15:05:09]: β–Έ i  uploading distribution...
[15:05:10]: β–Έ Error: failed to upload distribution. HTTP Error: 413, Unknown Error
Shell command exited with exit status 1 instead of 0.

Any one can confirm the size limitation? or maybe point me to the right direction?

Installation fails with exception (installing unf_ext (0.0.7.6), and Bundler cannot continue.)

extconf failed, exit code 1

Gem files will remain installed in /Users/sreekumarav/.fastlane/bin/bundle/lib/ruby/gems/2.2.0/gems/unf_ext-0.0.7.6 for inspection.
Results logged to /Users/sreekumarav/.fastlane/bin/bundle/lib/ruby/gems/2.2.0/extensions/x86_64-darwin-15/2.2.0-static/unf_ext-0.0.7.6/gem_make.out

An error occurred while installing unf_ext (0.0.7.6), and Bundler cannot continue.
Make sure that gem install unf_ext -v '0.0.7.6' succeeds before bundling.

βœ… fastlane environment βœ…

Stack

Key Value
OS 10.14.6
Ruby 2.2.4
Bundler? false
Git git version 2.20.1 (Apple Git-117)
Installation Source ~/.fastlane/bin/bundle/bin/fastlane
Host Mac OS X 10.14.6 (18G95)
Ruby Lib Dir ~/.fastlane/bin/bundle/lib
OpenSSL Version OpenSSL 1.0.2g 1 Mar 2016
Is contained false
Is homebrew true
Is installed via Fabric.app false
Xcode Path /Applications/Xcode.app/Contents/Developer/
Xcode Version 10.3

System Locale

Variable Value
LANG en_US.UTF-8 βœ…
LC_ALL en_US.UTF-8 βœ…
LANGUAGE en_US.UTF-8 βœ…

fastlane files:

`./fastlane/Fastfile`
# Customise this file, documentation can be found here:
# https://github.com/fastlane/fastlane/tree/master/fastlane/docs
# All available actions: https://docs.fastlane.tools/actions
# can also be listed using the `fastlane actions` command

# Change the syntax highlighting to Ruby
# All lines starting with a # are ignored when running `fastlane`

# If you want to automatically update fastlane if a new version is available:
# update_fastlane

# This is the minimum version number required.
# Update this, if you use features of a newer version
fastlane_version "2.28.3"

default_platform :android

platform :android do
  before_all do
    # ENV["SLACK_URL"] = "https://hooks.slack.com/services/..."
  end

  desc "Runs all the tests"
  lane :test do
    gradle(task: "test")
  end

  desc "Submit a new Beta Build to Crashlytics Beta"
  lane :beta do
    gradle(task: "assembleRelease")
    crashlytics

    # sh "your_script.sh"
    # You can also use other beta testing services here
  end

  desc "Deploy a new version to the Google Play"
  lane :deploy do
    gradle(task: "assembleRelease")
    supply
  end

  desc "Deploying Beta to firebase"
      lane :distribute do
          firebase_app_distribution(
              app: "1:717023762309:android:1a7c9bca3ad336709656ec",
              testers: "[email protected], [email protected]",
              release_notes: "Lots of amazing new features to test out!",
              firebase_cli_path: "/usr/local/bin/firebase"
          )

      end

  # You can define as many lanes as you want

  after_all do |lane|
    # This block is called, only if the executed lane was successful

    # slack(
    #   message: "Successfully deployed new App Update."
    # )
  end

  error do |lane, exception|
    # slack(
    #   message: exception.message,
    #   success: false
    # )
  end
end


# More information about multiple platforms in fastlane: https://github.com/fastlane/fastlane/blob/master/fastlane/docs/Platforms.md
# All available actions: https://docs.fastlane.tools/actions

# fastlane reports which actions are used
# No personal data is sent or shared. Learn more at https://github.com/fastlane/enhancer
`./fastlane/Appfile`
json_key_file "" # Path to the json secret file - Follow https://github.com/fastlane/supply#setup to get one
package_name "com.koin.sample" # e.g. com.krausefx.app

fastlane gems

Gem Version Update-Status
fastlane 2.28.3 πŸ’₯ Check failed

Loaded fastlane plugins:

Plugin Version Update-Status
fastlane-plugin-firebase_app_distribution 0.1.4 πŸ’₯ Check failed
Loaded gems
Gem Version
slack-notifier 1.5.1
atomos 0.1.3
claide 1.0.3
colored2 3.1.2
nanaimo 0.2.6
xcodeproj 1.12.0
rouge 2.0.7
xcpretty 0.3.0
terminal-notifier 1.7.1
unicode-display_width 1.1.3
terminal-table 1.7.3
CFPropertyList 2.3.5
multipart-post 2.0.0
word_wrap 1.0.0
tty-screen 0.5.0
colored 1.2
commander-fastlane 4.4.6
faraday 0.12.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
gh_inspector 1.1.3
uber 0.0.15
representable 2.3.0
retriable 2.1.0
mime-types 3.1
hurley 0.2
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.1
httpclient 2.8.3
google-api-client 0.9.28
json 1.8.1
mini_magick 4.5.1
multi_xml 0.6.0
rubyzip 1.3.0
security 0.1.3
xcpretty-travis-formatter 0.0.4
bundler 1.14.6
faraday_middleware 0.11.0.1
highline 1.7.10
excon 0.67.0
plist 3.5.0
babosa 1.0.3
fastimage 2.1.7
fastlane-plugin-firebase_app_distribution 0.1.4

generated on: 2019-10-13

Could not find action, lane or variable 'android'

I tried to run this command bundle exec fastlane android distribute
and got this error

+-------------------------------------------+---------+---------------------------+
|                                  Used plugins                                   |
+-------------------------------------------+---------+---------------------------+
| Plugin                                    | Version | Action                    |
+-------------------------------------------+---------+---------------------------+
| fastlane-plugin-firebase_app_distribution | 0.1.4   | firebase_app_distribution |
+-------------------------------------------+---------+---------------------------+

[15:28:34]: ------------------------------
[15:28:34]: --- Step: default_platform ---
[15:28:34]: ------------------------------
[15:28:34]: Driving the lane 'android distribute' πŸš€
+------------------+--------------------+
|             Lane Context              |
+------------------+--------------------+
| DEFAULT_PLATFORM | android            |
| PLATFORM_NAME    | android            |
| LANE_NAME        | android distribute |
+------------------+--------------------+
[15:28:34]: Could not find action, lane or variable 'android'. Check out the documentation for more details: https://docs.fastlane.tools/actions

+------+------------------+-------------+
|           fastlane summary            |
+------+------------------+-------------+
| Step | Action           | Time (in s) |
+------+------------------+-------------+
| 1    | default_platform | 0           |
+------+------------------+-------------+

[15:28:34]: fastlane finished with errors

[!] Could not find action, lane or variable 'android'. Check out the documentation for more details: https://docs.fastlane.tools/actions

Here is my distribute lane

lane :distribute do
    firebase_app_distribution(
      app: FIREBASE_ANDROID_APP_ID,
      testers: FIREBASE_TESTERS,
      release_notes: get_latest_changelog('android'),
      firebase_cli_path: "/Users/binhnd/.nvm/versions/node/v10.18.1/bin/firebase",
      apk_path: android/app/build/outputs/apk/development/release/app-development-release.apk
    )
  end

My env

Bundler version 2.1.4
ruby 2.6.3p62 (2019-04-16 revision 67580) [universal.x86_64-darwin19]
fastlane 2.146.1
gem 3.0.3

The error message Could not find action, lane or variable 'android' is so strange as I can run other lanes normally

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    πŸ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. πŸ“ŠπŸ“ˆπŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❀️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.