Bug 1999534

Summary: module ruby 3.0: User-installed rubygems plugins are not being loaded
Product: [Fedora] Fedora Modules Reporter: Jarek Prokop <jprokop>
Component: rubyAssignee: Jarek Prokop <jprokop>
Status: CLOSED EOL QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: unspecifiedCC: jaruga, jprokop, mkocka, phracek, ppisar, pvalena, rbean, ruby-packagers-sig
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: ruby-3.0-3420210902142138.058368ca ruby-3.0-20210902142138.8b234a03 ruby-3.0-3520210902142138.f27b74a8 ruby-3.0-3320210902142138.601d93de Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2024-06-21 08:25:28 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On: 1999479    
Bug Blocks:    

Description Jarek Prokop 2021-08-31 08:46:48 UTC
Description of problem:
User-installed rubygems plugins are not being loaded correctly.

Version-Release number of selected component (if applicable):
ruby-3.0.{0,1,2}

How reproducible:
Always

Steps to Reproduce:
1. gem install geminabox --user-install
2. gem inabox --help

Actual results:
~~~
$ gem inabox --help
ERROR:  While executing gem ... (Gem::CommandLineError)
    Unknown command inabox
~~~

Expected results:
~~~
$ gem inabox --help
Usage: gem inabox GEM [options]

  Options:
    -c, --configure                  Configure GemInABox
    -g, --host HOST                  Host to upload to.
    -o, --overwrite                  Overwrite Gem.
    -p, --port                       Sets port


  Common Options:
    -h, --help                       Get help on this command
    -V, --[no-]verbose               Set the verbose level of output
    -q, --quiet                      Silence command progress meter
        --silent                     Silence RubyGems output
        --config-file FILE           Use this config file instead of default
        --backtrace                  Show stack backtrace on errors
        --debug                      Turn on Ruby debugging
        --norc                       Avoid loading any .gemrc file


  Arguments:
    GEM       built gem to push up

  Summary:
    Push a gem up to your GemInABox

  Description:
    Push a gem up to your GemInABox
~~~

Additional info:
A possible workaround is pre-loading the gem, like so
`$ RUBYOPT=-r<gem> gem <command>`
Or specifying $GEM_HOME:
`$ GEM_HOME=/builddir/.local/share/gem/ruby/3.0.0 gem <command>`

The issue was fixed upstream: https://github.com/rubygems/rubygems/pull/4829

Comment 1 Jun Aruga 2021-08-31 13:26:23 UTC
I confirmed this issue was fixed by the following patch on rpms/ruby rawhide.
https://src.fedoraproject.org/rpms/ruby/c/11a27766bd500e054f71bcbc283e12bacb2a275e?branch=rawhide

```
<mock-chroot> sh-5.1$ rpm -q ruby
ruby-3.0.2-152.fc36.x86_64
```

So, I think the solution for modules/ruby 3.0 branch is just to rebuild the module.

Comment 2 Jarek Prokop 2021-09-06 21:47:57 UTC
I fired the rebuild for the module, f36 Ruby is failing to build.

Looks like it can't be built until rhbz#1999479 is fixed.