Hide Forgot
The json gem is never found when using bundler. This points to a configuration problem. Check this bug for reference: https://github.com/hanami/hanami/issues/512 On Funtoo/Gentoo, the exact same example works fine.
Hello Renich, We are still evaluating how to tackle this. For the time being, please add json into your package dependencies or into your application Gemfile. If this is urgent matter for you, please contact Red Hat support to help us prioritize this issue.
Thanks for the update Vit.
Due to Ruby on Rails 5.0 support, we were forced to narrow this in Fedora, so I think it is reasonable to apply the same patch in RHEL as well. [1] http://pkgs.fedoraproject.org/cgit/rpms/ruby.git/commit/ruby.spec?id=b1466a4c8f2cd28556efcd93c5dc539bff041be9
This should always work: ~~~ $ ruby -e "p(require 'json')" true ~~~ Give these prerequisites: ~~~ $ bundle init $ cat Gemfile # A sample Gemfile source "https://rubygems.org" # gem "rails" $ bundle install The Gemfile specifies no dependencies Resolving dependencies... Your bundle is complete! Use `bundle show [gemname]` to see where a bundled gem is installed. ~~~ This does not work with current ruby-2.0.0.648-29.el7 ~~~ $ bundle exec ruby -e "p(require 'json')" -e:1:in `require': cannot load such file -- json (LoadError) from -e:1:in `<main>' ~~~ but it should be fixed by ruby-2.0.0.648-30.el7: ~~~ $ bundle exec ruby -e "p(require 'json')" true ~~~
Since the problem described in this bug report should be resolved in a recent advisory, it has been closed with a resolution of ERRATA. For information on the advisory, and where to find the updated files, follow the link below. If the solution does not work for you, open a new bug report. https://access.redhat.com/errata/RHBA-2017:2037