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

Can't install with Ruby 2.5 #598

Closed
falsandtru opened this issue Dec 26, 2017 · 17 comments
Closed

Can't install with Ruby 2.5 #598

falsandtru opened this issue Dec 26, 2017 · 17 comments

Comments

@falsandtru
Copy link

Could you support Ruby 2.5?

$ bundle update
Fetching gem metadata from https://rubygems.org/............
Fetching gem metadata from https://rubygems.org/..
Resolving dependencies.......
Using concurrent-ruby 1.0.5
Using i18n 0.9.1
Using minitest 5.10.3
Using thread_safe 0.3.6
Using tzinfo 1.2.4
Using activesupport 4.2.9
Using public_suffix 2.0.5
Using addressable 2.5.2
Using bundler 1.16.1
Using coffee-script-source 1.11.1
Using execjs 2.7.0
Using coffee-script 2.4.1
Using colorator 1.1.0
Using ruby-enum 0.7.1
Using commonmarker 0.17.7.1
Fetching ffi 1.9.18 (x64-mingw32)
Installing ffi 1.9.18 (x64-mingw32)
Gem::RuntimeRequirementNotMetError: ffi requires Ruby version < 2.5, >= 2.0. The
current ruby version is 2.5.0.
An error occurred while installing ffi (1.9.18), and Bundler cannot continue.
Make sure that `gem install ffi -v '1.9.18'` succeeds before bundling.

In Gemfile:
  github-pages was resolved to 172, which depends on
    github-pages-health-check was resolved to 1.3.5, which depends on
      typhoeus was resolved to 0.8.0, which depends on
        ethon was resolved to 0.11.0, which depends on
          ffi
$ gem install ffi -v '1.9.18'
ERROR:  Error installing ffi:
        The last version of ffi (= 1.9.18) to support your Ruby & RubyGems was 1.9.18. Try installing it with `gem install ffi -v 1.9.18`
        ffi requires Ruby version < 2.5, >= 2.0. The current ruby version is 2.5.0.
@alexdevero
Copy link

alexdevero commented Dec 28, 2017

I have the same problem when I try to install sass gem:

$ gem install sass
ERROR:  Error installing sass:
        The last version of ffi (< 2, >= 0.5.0) to support your Ruby & RubyGems was 1.9.18. Try installing it with `gem install ffi -v 1.9.18` and then running the current command again
        ffi requires Ruby version < 2.5, >= 2.0. The current ruby version is 2.5.0.

$ gem install ffi -v 1.9.18                                                            
ERROR:  Error installing ffi:                                                          
        The last version of ffi (= 1.9.18) to support your Ruby & RubyGems was 1.9.18. 
Try installing it with `gem install ffi -v 1.9.18`                                     
        ffi requires Ruby version < 2.5, >= 2.0. The current ruby version is 2.5.0.    

@busayyyo
Copy link

busayyyo commented Jan 1, 2018

Same here when I tried installing jekyll:

C:\Windows\system32>gem install jekyll
ERROR:  Error installing jekyll:
        The last version of ffi (< 2, >= 0.5.0) to support your Ruby & RubyGems was 1.9.18. Try installing it with `gem install ffi -v 1.9.18` and then running the current command again
        ffi requires Ruby version < 2.5, >= 2.0. The current ruby version is 2.5.0.

C:\Windows\system32>gem install ffi -v 1.9.18
ERROR:  Error installing ffi:
        The last version of ffi (= 1.9.18) to support your Ruby & RubyGems was 1.9.18. Try installing it with `gem install ffi -v 1.9.18`
        ffi requires Ruby version < 2.5, >= 2.0. The current ruby version is 2.5.0.

@vbortone
Copy link

vbortone commented Jan 2, 2018

I used gem install ffi -f to get around this in Ruby 2,5 under Windows. I haven't tested it yet, but it gets me past the error message.

@busayyyo
Copy link

busayyyo commented Jan 3, 2018

This helped bypass the errors, thank you!

@alexdevero
Copy link

alexdevero commented Jan 3, 2018

Thanks a lot @vbortone! Your solution worked for me as well, on Windows 10. I was finally able to install sass gem after using it. 👍

@reageek
Copy link

reageek commented Jan 4, 2018

the above install issue is resolved with -f flag. However it creates other issues with resources dependent on ffi which fails to validate against the lastest ruby versions. For example bundler install on a fresh jekyll project will result in the following:

$ bundler install
Fetching gem metadata from https://rubygems.org/............
ffi-1.9.18-x64-mingw32 requires ruby version < 2.5, >= 2.0, which is
incompatible with the current version, ruby 2.5.0p0

Seems the most current ruby version convention is problematic.

You can go around this by manually installing gems....

@ShmyhelskyiK
Copy link

@vbortone , thanks, really helped

@larskanis
Copy link
Member

@tduehr, @headius Could you please publish a new release, so that ffi works out of the box on Windows ruby-2.5?

@Prometey13
Copy link

Thanks @vbortone! It helped

@sandeeppoloju
Copy link

@vbortone, Thank you very much. It fixed my problem.

@jbrach
Copy link

jbrach commented Feb 4, 2018

Thank You @vbortone. Fixed my problem

@VillSource
Copy link

Thank you so much.
It save my life.
@vbortone

@headius
Copy link
Contributor

headius commented Feb 6, 2018 via email

@vbortone
Copy link

vbortone commented Feb 6, 2018 via email

@claudiuconstantin
Copy link

claudiuconstantin commented Nov 24, 2018

I'm still getting ffi-1.9.18-x64-mingw32 requires ruby version < 2.5, which is incompatible with the current version, ruby 2.5.1p57 on Windows 10. Any updates on this?

@claudiuconstantin
Copy link

Oh, nevermind, I ran a bundle update and everything's fixed for me 👍

@gregsdennis
Copy link

gregsdennis commented Feb 16, 2020

Now getting the same thing for Ruby 2.7:

ffi requires Ruby version >= 2.2, < 2.7.dev.  The current ruby version is 2.7.0.0.

I forced the install of the gem, and now I get this when running bundle install

Fetching gem metadata from https://rubygems.org/.........
ffi-1.11.2-x64-mingw32 requires ruby version >= 2.2, < 2.7.dev, which is incompatible with the current version, ruby 2.7.0p0

NVM - bundle update fixed for ffi... now getting for nokogiri. Guess I'll go find that repo now...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests