Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

firebase_app_distribution plugin doesn't work in macOS Catalina #15506

Closed
4 tasks done
fromkk opened this issue Oct 16, 2019 · 14 comments · Fixed by fastlane/docs#877 or #15532
Closed
4 tasks done

firebase_app_distribution plugin doesn't work in macOS Catalina #15506

fromkk opened this issue Oct 16, 2019 · 14 comments · Fixed by fastlane/docs#877 or #15532

Comments

@fromkk
Copy link

fromkk commented Oct 16, 2019

New Issue Checklist

Issue Description

I'd like to try to use firebase_app_distribution plugin with Fastlane.
So I executed fastlane add_plugin firebase_app_distribution and use with fastlane firebase_app_distribution command.
But, failed with error.

Command executed
fastlane add_plugin firebase_app_distribution
[✔] 🚀 
[11:11:34]: fastlane detected a Gemfile in the current directory
[11:11:34]: however it seems like you don't use `bundle exec`
[11:11:34]: to launch fastlane faster, please use
[11:11:34]: 
[11:11:34]: $ bundle exec fastlane add_plugin firebase_app_distribution
[11:11:34]: 
[11:11:34]: Get started using a Gemfile for fastlane https://docs.fastlane.tools/getting-started/ios/setup/#use-a-gemfile
[11:11:35]: Plugin 'fastlane-plugin-firebase_app_distribution' was added to './fastlane/Pluginfile'
[11:11:35]: Make sure to commit your Gemfile, Gemfile.lock and Pluginfile to version control
Installing plugin dependencies...
Successfully installed plugins
Complete output when running fastlane, including the stack trace and command used
fastlane firebase_app_distribution
[✔] 🚀 
[11:12:46]: fastlane detected a Gemfile in the current directory
[11:12:46]: however it seems like you don't use `bundle exec`
[11:12:46]: to launch fastlane faster, please use
[11:12:46]: 
[11:12:46]: $ bundle exec fastlane firebase_app_distribution
[11:12:46]: 
[11:12:46]: Get started using a Gemfile for fastlane https://docs.fastlane.tools/getting-started/ios/setup/#use-a-gemfile
[11:12:47]: Error loading plugin 'fastlane-plugin-firebase_app_distribution': cannot load such file -- fastlane/plugin/firebase_app_distribution
[11:12:47]: It seems like you wanted to load some plugins, however they couldn't be loaded
[11:12:47]: Please follow the troubleshooting guide: https://docs.fastlane.tools/plugins/plugins-troubleshooting/
+-------------------------------------------+-----------+------------------+
|                               Used plugins                               |
+-------------------------------------------+-----------+------------------+
| Plugin                                    | Version   | Action           |
+-------------------------------------------+-----------+------------------+
| fastlane-plugin-firebase_app_distribution | undefined | No actions found |
+-------------------------------------------+-----------+------------------+
[11:12:47]: ----------------------------------------
[11:12:47]: --- Step: Verifying fastlane version ---
[11:12:47]: ----------------------------------------
[11:12:47]: Your fastlane version 2.134.0 matches the minimum requirement of 2.119.0  ✅
[11:12:47]: ------------------------------
[11:12:47]: --- Step: default_platform ---
[11:12:47]: ------------------------------
+------------------+-----+
|      Lane Context      |
+------------------+-----+
| DEFAULT_PLATFORM | ios |
+------------------+-----+
[11:12:47]: Could not find lane 'ios firebase_app_distribution'. Available lanes: ios version, ios deploy, ios test, ios beta, ios release, ios dsyms
+------+----------------------------+-------------+
|                fastlane summary                 |
+------+----------------------------+-------------+
| Step | Action                     | Time (in s) |
+------+----------------------------+-------------+
| 1    | Verifying fastlane version | 0           |
| 2    | default_platform           | 0           |
+------+----------------------------+-------------+
Looking for related GitHub issues on fastlane/fastlane...
➡️  Malformed version number string undefined
    https://github.com/fastlane/fastlane/issues/14663 [closed] 1 💬
    23 Jun 2019
➡️  Sign in with the app-specific password you generated
    https://github.com/fastlane/fastlane/issues/7380 [closed] 5 💬
    22 Aug 2017
🔗  You can ⌘ + double-click on links to open them directly in your browser.
Traceback (most recent call last):
    20: from /usr/local/bin/fastlane:23:in `'
    19: from /usr/local/bin/fastlane:23:in `load'
    18: from /Library/Ruby/Gems/2.6.0/gems/fastlane-2.134.0/bin/fastlane:23:in `'
    17: from /Library/Ruby/Gems/2.6.0/gems/fastlane-2.134.0/fastlane/lib/fastlane/cli_tools_distributor.rb:119:in `take_off'
    16: from /Library/Ruby/Gems/2.6.0/gems/fastlane-2.134.0/fastlane/lib/fastlane/commands_generator.rb:41:in `start'
    15: from /Library/Ruby/Gems/2.6.0/gems/fastlane-2.134.0/fastlane/lib/fastlane/commands_generator.rb:349:in `run'
    14: from /Library/Ruby/Gems/2.6.0/gems/commander-fastlane-4.4.6/lib/commander/delegates.rb:15:in `run!'
    13: from /Library/Ruby/Gems/2.6.0/gems/fastlane-2.134.0/fastlane_core/lib/fastlane_core/ui/fastlane_runner.rb:76:in `run!'
    12: from /Library/Ruby/Gems/2.6.0/gems/commander-fastlane-4.4.6/lib/commander/runner.rb:476:in `run_active_command'
    11: from /Library/Ruby/Gems/2.6.0/gems/commander-fastlane-4.4.6/lib/commander/command.rb:153:in `run'
    10: from /Library/Ruby/Gems/2.6.0/gems/commander-fastlane-4.4.6/lib/commander/command.rb:178:in `call'
     9: from /Library/Ruby/Gems/2.6.0/gems/fastlane-2.134.0/fastlane/lib/fastlane/commands_generator.rb:108:in `block (2 levels) in run'
     8: from /Library/Ruby/Gems/2.6.0/gems/fastlane-2.134.0/fastlane/lib/fastlane/command_line_handler.rb:36:in `handle'
     7: from /Library/Ruby/Gems/2.6.0/gems/fastlane-2.134.0/fastlane/lib/fastlane/lane_manager.rb:76:in `cruise_lane'
     6: from /Library/Ruby/Gems/2.6.0/gems/fastlane-2.134.0/fastlane/lib/fastlane/lane_manager_base.rb:20:in `finish_fastlane'
     5: from /Library/Ruby/Gems/2.6.0/gems/fastlane-2.134.0/fastlane/lib/fastlane/plugins/plugin_update_manager.rb:26:in `show_update_status'
     4: from /Library/Ruby/Gems/2.6.0/gems/fastlane-2.134.0/fastlane/lib/fastlane/plugins/plugin_update_manager.rb:26:in `each'
     3: from /Library/Ruby/Gems/2.6.0/gems/fastlane-2.134.0/fastlane/lib/fastlane/plugins/plugin_update_manager.rb:29:in `block in show_update_status'
     2: from /System/Library/Frameworks/Ruby.framework/Versions/2.6/usr/lib/ruby/2.6.0/rubygems/version.rb:203:in `new'
     1: from /System/Library/Frameworks/Ruby.framework/Versions/2.6/usr/lib/ruby/2.6.0/rubygems/version.rb:203:in `new'
/System/Library/Frameworks/Ruby.framework/Versions/2.6/usr/lib/ruby/2.6.0/rubygems/version.rb:212:in `initialize': Malformed version number string undefined (ArgumentError)
    20: from /usr/local/bin/fastlane:23:in `'
    19: from /usr/local/bin/fastlane:23:in `load'
    18: from /Library/Ruby/Gems/2.6.0/gems/fastlane-2.134.0/bin/fastlane:23:in `'
    17: from /Library/Ruby/Gems/2.6.0/gems/fastlane-2.134.0/fastlane/lib/fastlane/cli_tools_distributor.rb:119:in `take_off'
    16: from /Library/Ruby/Gems/2.6.0/gems/fastlane-2.134.0/fastlane/lib/fastlane/commands_generator.rb:41:in `start'
    15: from /Library/Ruby/Gems/2.6.0/gems/fastlane-2.134.0/fastlane/lib/fastlane/commands_generator.rb:349:in `run'
    14: from /Library/Ruby/Gems/2.6.0/gems/commander-fastlane-4.4.6/lib/commander/delegates.rb:15:in `run!'
    13: from /Library/Ruby/Gems/2.6.0/gems/fastlane-2.134.0/fastlane_core/lib/fastlane_core/ui/fastlane_runner.rb:76:in `run!'
    12: from /Library/Ruby/Gems/2.6.0/gems/commander-fastlane-4.4.6/lib/commander/runner.rb:476:in `run_active_command'
    11: from /Library/Ruby/Gems/2.6.0/gems/commander-fastlane-4.4.6/lib/commander/command.rb:153:in `run'
    10: from /Library/Ruby/Gems/2.6.0/gems/commander-fastlane-4.4.6/lib/commander/command.rb:178:in `call'
     9: from /Library/Ruby/Gems/2.6.0/gems/fastlane-2.134.0/fastlane/lib/fastlane/commands_generator.rb:108:in `block (2 levels) in run'
     8: from /Library/Ruby/Gems/2.6.0/gems/fastlane-2.134.0/fastlane/lib/fastlane/command_line_handler.rb:36:in `handle'
     7: from /Library/Ruby/Gems/2.6.0/gems/fastlane-2.134.0/fastlane/lib/fastlane/lane_manager.rb:76:in `cruise_lane'
     6: from /Library/Ruby/Gems/2.6.0/gems/fastlane-2.134.0/fastlane/lib/fastlane/lane_manager_base.rb:20:in `finish_fastlane'
     5: from /Library/Ruby/Gems/2.6.0/gems/fastlane-2.134.0/fastlane/lib/fastlane/plugins/plugin_update_manager.rb:26:in `show_update_status'
     4: from /Library/Ruby/Gems/2.6.0/gems/fastlane-2.134.0/fastlane/lib/fastlane/plugins/plugin_update_manager.rb:26:in `each'
     3: from /Library/Ruby/Gems/2.6.0/gems/fastlane-2.134.0/fastlane/lib/fastlane/plugins/plugin_update_manager.rb:29:in `block in show_update_status'
     2: from /System/Library/Frameworks/Ruby.framework/Versions/2.6/usr/lib/ruby/2.6.0/rubygems/version.rb:203:in `new'
     1: from /System/Library/Frameworks/Ruby.framework/Versions/2.6/usr/lib/ruby/2.6.0/rubygems/version.rb:203:in `new'
/System/Library/Frameworks/Ruby.framework/Versions/2.6/usr/lib/ruby/2.6.0/rubygems/version.rb:212:in `initialize': [!] Malformed version number string undefined (ArgumentError)
    11: from /usr/local/bin/fastlane:23:in `'
    10: from /usr/local/bin/fastlane:23:in `load'
     9: from /Library/Ruby/Gems/2.6.0/gems/fastlane-2.134.0/bin/fastlane:23:in `'
     8: from /Library/Ruby/Gems/2.6.0/gems/fastlane-2.134.0/fastlane/lib/fastlane/cli_tools_distributor.rb:119:in `take_off'
     7: from /Library/Ruby/Gems/2.6.0/gems/fastlane-2.134.0/fastlane/lib/fastlane/commands_generator.rb:53:in `start'
     6: from /Library/Ruby/Gems/2.6.0/gems/fastlane-2.134.0/fastlane/lib/fastlane/commands_generator.rb:43:in `ensure in start'
     5: from /Library/Ruby/Gems/2.6.0/gems/fastlane-2.134.0/fastlane/lib/fastlane/plugins/plugin_update_manager.rb:26:in `show_update_status'
     4: from /Library/Ruby/Gems/2.6.0/gems/fastlane-2.134.0/fastlane/lib/fastlane/plugins/plugin_update_manager.rb:26:in `each'
     3: from /Library/Ruby/Gems/2.6.0/gems/fastlane-2.134.0/fastlane/lib/fastlane/plugins/plugin_update_manager.rb:29:in `block in show_update_status'
     2: from /System/Library/Frameworks/Ruby.framework/Versions/2.6/usr/lib/ruby/2.6.0/rubygems/version.rb:203:in `new'
     1: from /System/Library/Frameworks/Ruby.framework/Versions/2.6/usr/lib/ruby/2.6.0/rubygems/version.rb:203:in `new'
/System/Library/Frameworks/Ruby.framework/Versions/2.6/usr/lib/ruby/2.6.0/rubygems/version.rb:212:in `initialize': Malformed version number string undefined (ArgumentError)
  

Environment

🚫 fastlane environment 🚫

Stack

Key Value
OS 10.15
Ruby 2.6.3
Bundler? false
Git git version 2.21.0
Installation Source /usr/local/bin/fastlane
Host Mac OS X 10.15 (19A583)
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.0

System Locale

Error
No Locale with UTF8 found 🚫

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.119.0"

appVersion = "3.0.0"
xcodeproj = "Type.xcodeproj"
buildNumber = `git log --oneline | wc -l`.strip


default_platform :ios

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

  lane :version do |options|
    version_number = options[:version] || appVersion
    increment_version_number(version_number: version_number, xcodeproj: xcodeproj)
    increment_build_number(build_number: buildNumber, xcodeproj: xcodeproj)
  end

  lane :deploy do |options|
    commit_message = `git log --format=%B -n 1 HEAD`.strip
    ipa_path = options[:ipa_path]
    app_id = options[:app_id] || "1:22804013810:ios:ee16d150e1ffecd2"
    groups = options[:groups] || "開発者"
    firebase_cli_path = options[:firebase_cli_path] || "/usr/local/lib/node_modules/firebase-tools/lib/bin/firebase.js"

    firebase_app_distribution(
        app: app_id,
        groups: groups,
        release_notes: commit_message,
        ipa_path: ipa_path,
        firebase_cli_path: firebase_cli_path
    )
  end

  desc "Runs all the tests"
  lane :test do
    scan
  end

  desc "Submit a new Beta Build to Apple TestFlight"
  desc "This will also make sure the profile is up to date"
  lane :beta do
    # match(type: "appstore") # more information: https://codesigning.guide
    gym(scheme: "Type") # Build your app - more options available
    pilot

    # sh "your_script.sh"
    # You can also use other beta testing services here (run `fastlane actions`)
  end

  desc "Deploy a new version to the App Store"
  lane :release do
    # match(type: "appstore")
    # snapshot
    # gym(scheme: "Type") # Build your app - more options available
    deliver(force: true)
    # frameit
  end

  lane :dsyms do |options|
    version_number = options[:version] || get_info_plist_value(path: 'Type/Info.plist', key: "CFBundleShortVersionString")
    app_identifier = "me.fromkk.Type"
    download_dsyms(
      version: version_number,
      app_identifier: app_identifier
    )
    upload_symbols_to_crashlytics(
      gsp_path: "Type/Resources/GoogleService-Info.plist"
    )
    clean_build_artifacts
  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 recorded. 
# Learn more at https://github.com/fastlane/fastlane#metrics
`./fastlane/Appfile`
app_identifier "me.fromkk.Type" # The bundle identifier of your app
apple_id "iueokakkun@gmail.com" # Your Apple email address

team_id "K84E4S7G4C" # Developer Portal Team ID

# you can even provide different app identifiers, Apple IDs and team names per lane:
# More information: https://github.com/fastlane/fastlane/blob/master/fastlane/docs/Appfile.md

fastlane gems

Gem Version Update-Status
fastlane 2.134.0 ✅ Up-To-Date

Loaded fastlane plugins:

Plugin Version Update-Status
fastlane-plugin-badge 1.3.0 ✅ Up-To-Date
Loaded gems
Gem Version
did_you_mean 1.3.0
slack-notifier 2.3.2
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 2.0.0
unicode-display_width 1.6.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
tty-screen 0.7.0
tty-cursor 0.7.0
tty-spinner 0.9.1
babosa 1.0.3
colored 1.2
highline 1.7.10
commander-fastlane 4.4.6
excon 0.67.0
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 0.17.0
faraday_middleware 0.13.1
fastimage 2.1.7
gh_inspector 1.1.3
mini_magick 4.9.5
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
naturally 2.2.0
simctl 1.6.6
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
mime-types 3.3
memoist 0.16.0
os 1.0.1
googleauth 0.6.7
httpclient 2.8.3
google-api-client 0.23.9
digest-crc 0.4.1
google-cloud-storage 1.16.0
emoji_regex 1.0.1
CFPropertyList 3.0.1
json 2.2.0
mime-types-data 3.2019.1009
multi_json 1.14.1
signet 0.12.0
google-cloud-env 1.2.1
google-cloud-core 1.3.2
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
curb 0.9.10
badge 0.11.0
fastlane-plugin-badge 1.3.0

generated on: 2019-10-16

@oleksiiparf
Copy link

I've faced with identical issue on Ubuntu 18.04.1. Plugin installed, but can't be loaded.

@oleksiiparf
Copy link

Looks like the fastlane firebase_app_distribution or fastlane env commands has not enough privileges to get access to plugin. Try to run command as Administrator.

@janpio
Copy link
Member

janpio commented Oct 17, 2019

Did you search for previous issues about this plugin?
Did you post this at the plugin's Github repo?

@janpio janpio changed the title Don't install plugin in macOS Catalina firebase_app_distribution plugin doesn't work in macOS Catalina Oct 17, 2019
@timMorrill
Copy link

I'm having the same issue on Mojave

@drayan85
Copy link

I'm also having the same issue on Mojave

@drayan85
Copy link

Upgrade ruby to 2.5.5 will work

@drayan85
Copy link

@Peretz30
Copy link

You need to edit Fastfile like in the docs
https://firebase.google.com/docs/app-distribution/ios/distribute-fastlane

@joshdholtz
Copy link
Member

joshdholtz commented Oct 21, 2019

@fromkk Heyyy 👋 The command should be fastlane run firebase_app_distribution (not fastlane firebase_app_distribution ). The run is important 😇

But also, there is still an issue with finding that firebase_app_distribution action from within the plugin that I'm looking into.


And most likely you will want to use bundle exec fastlane run firebase_app_distribution to make sure that you are using all the proper dependencies that are define in the Gemfile and fastlane/Pluginfile

@fastlane-bot
Copy link

The pull request #15532 that closed this issue was merged and released as part of fastlane 2.135.0 🚀
Please let us know if the functionality works as expected as a reply here. If it does not, please open a new issue. Thanks!

@michzio
Copy link

michzio commented Dec 10, 2019

In my case the error was resolved after using

sudo fastlane firebase_app_distribution

Also mu custom lane to distribute app via firebase need to start with sudo

sudo fastlane my_custom_distribution_lane

@gkhloptov
Copy link

Looks like files in firebase_app_distribution plugin have incorrect permissions, 640 by default. This can be fixed with

sudo chmod -R a+r /Library/Ruby/Gems/2.6.0/gems/fastlane-plugin-firebase_app_distribution-0.1.4

so you don't need to run fastlane itself with sudo

@derpoliuk
Copy link

@gkhloptov thank you, changing permissions helped me.

@herald25santos
Copy link

Hi sir gkhloptov! I can't update my rubygems into updated I'm currently using 2.3.7.

This error message that I got whenever I tried to update gems
ERROR: While executing gem ... (Gem::FilePermissionError)
You don't have write permissions for the /Library/Ruby/Gems/2.3.0 directory.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.