When attempting to use gem install nokogiri
I'm getting the following error:
ERROR: Error installing nokogiri:
nokogiri requires Ruby version < 2.3, >= 1.9.2.
However if I do ruby -v
:
ruby 2.3.0p0 (2015-12-25 revision 53290) [i386-mingw32]
I've attempted to install it locally, gem install --local nokogiri
and it runs through the install process, however when I attempt to use the gem, it won't find the file:
C:/Ruby23/lib/ruby/site_ruby/2.3.0/rubygems/core_ext/kernel_require.rb:55:in `require'
: cannot load such file -- nokogiri (LoadError)
Does anyone have a work around for this? Or am I pretty much stuck without nokogiri
?
After some hassle and some research, I used
gem install nokogiri --pre
and wouldn't you know it:I found the answer to this question here I've also looked into it on GitHub (as mentioned by Aaron_H) and it seems that this is only happening on Windows, so if you really need
nokogiri
you need to dogem install nokogiri --pre
in order to get it (on Windows 7 anyways).I think the answer was staring us in the face, your version of nokogiri requires Ruby less than 2.3, and you're running ruby 2.3.
It seems you're not the only one with this issue: https://github.com/sparklemotion/nokogiri/issues/1456