Closed shubham0390 closed 6 years ago
Hi @shubham0390,
That's probably because of the Safe Navigation Operator (&.). It's only available after Ruby version 2.3.0. If you have a previous version it won't work.
Cheers
Hi @bffcorreia the error still exist however the $ ruby --version ruby 2.4.4p296 (2018-03-28 revision 63013) [x86_64-linux-gnu]
Hi again @yassinelhadidy,
First of all sorry for my late response.
Not sure what could be, but it's probably some wrong configuration with your ruby / bundle / rubygems. Because your ruby version is the 2.4.4 but the path to your gems is in /gems/2.2.0/
.
Can you try to update your rubygem version: gem update --system
. And also the bundle version: gem install bundler
.
If you are using rbenv or rvm to manage ruby versions make sure you are using the correct version.
If the error still persists please copy the output of the gem env
command to here.
Cheers
Hi, I have the same issue when I try to add the plugin.
Here's the output of gem env
:
RubyGems Environment:
- RUBYGEMS VERSION: 2.7.7
- RUBY VERSION: 2.5.1 (2018-03-29 patchlevel 57) [x86_64-darwin17]
- INSTALLATION DIRECTORY: /usr/local/lib/ruby/gems/2.5.0
- USER INSTALLATION DIRECTORY: /Users/scott/.gem/ruby/2.5.0
- RUBY EXECUTABLE: /usr/local/opt/ruby/bin/ruby
- EXECUTABLE DIRECTORY: /usr/local/bin
- SPEC CACHE DIRECTORY: /Users/scott/.gem/specs
- SYSTEM CONFIGURATION DIRECTORY: /usr/local/Cellar/ruby/2.5.1/etc
- RUBYGEMS PLATFORMS:
- ruby
- x86_64-darwin-17
- GEM PATHS:
- /usr/local/lib/ruby/gems/2.5.0
- /Users/scott/.gem/ruby/2.5.0
- /usr/local/Cellar/ruby/2.5.1/lib/ruby/gems/2.5.0
- GEM CONFIGURATION:
- :update_sources => true
- :verbose => true
- :backtrace => false
- :bulk_threshold => 1000
- REMOTE SOURCES:
- https://rubygems.org/
- SHELL PATH:
- /Users/scott/go/bin
- /Users/scott/.fastlane/bin
- /Users/scott/bin
- /usr/local/bin
- /usr/local/bin
- /usr/bin
- /bin
- /usr/sbin
- /sbin
- /usr/local/go/bin
- /usr/local/share/dotnet
- /opt/X11/bin
- ~/.dotnet/tools
- /Library/Frameworks/Mono.framework/Versions/Current/Commands
Hi @soulcramer,
Can you also print the output error and the output of the ruby --version
command?
Everything looks fine in your gem env
. Maybe fastlane is picking a different version of Ruby?
Nevertheless, I will try to reproduce the error locally to understand what's going on.
Hi again @bffcorreia,
❯ ruby --version
ruby 2.5.1p57 (2018-03-29 revision 63029) [x86_64-darwin17]
I've also run fastlane env
(with its output here) and it does look like that Fastlane using a different version of Ruby.
So, the problem is that Fastlane is picking up other Ruby version that is lower than the 2.3.0. Check this question in the fastlane github and let me know if you were able to fix it :)
Hi @bffcorreia,
So, by installing and using rbenv and then installing Fastlane through gem install fastlane --verbose
, Fastlane use the correct version of ruby.
Cool @soulcramer :) I will close this issue, then. Feel free to open it if you still have any problem.
Following error occurs when installing the plugin --
Error loading plugin 'fastlane-plugin-run_tests_firebase_testlab': /Users/subhamtyagi/.fastlane/bin/bundle/lib/ruby/gems/2.2.0/gems/fastlane-plugin-run_tests_firebase_testlab-0.2.0/lib/fastlane/plugin/run_tests_firebase_testlab/actions/run_tests_firebase_testlab_action.rb:187: syntax error, unexpected '.' url = line.scan(/\[(.*)\]/).last&.first ^