Bug 33096

Summary: vagrant fails to run due to missing dependencies.
Product: Mageia Reporter: PC LX <mageia>
Component: RPM PackagesAssignee: All Packagers <pkg-bugs>
Status: NEW --- QA Contact:
Severity: critical    
Priority: Normal    
Version: 9   
Target Milestone: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Source RPM: vagrant-2.3.7-1.mga9.src.rpm CVE:
Status comment:

Description PC LX 2024-04-13 11:28:53 CEST
Description of problem:

System: Mageia 9, x86_64, AMD Ryzen 5 5600G with Radeon Graphics.

After installing vagrant with the following command:
"""
urpmi --no-recommends vagrant
"""

And running the following command:
"""
vagrant init
"""

The following output indicating a missing dependency "googleapis-common-protos-types":
"""
$ vagrant init
/usr/share/rubygems/rubygems/specification.rb:1453:in `rescue in block in activate_dependencies': Could not find 'googleapis-common-protos-types' (~> 1.3) among 110 total gem(s) (Gem::MissingSpecError)
Checked in 'GEM_PATH=/usr/share/gems:/usr/share/vagrant/gems:/home/pclx/.vagrant.d/gems' at: /usr/share/vagrant/gems/specifications/vagrant-2.3.7.gemspec, execute `gem env` for more information
        from /usr/share/rubygems/rubygems/specification.rb:1450:in `block in activate_dependencies'
        from /usr/share/rubygems/rubygems/specification.rb:1439:in `each'
        from /usr/share/rubygems/rubygems/specification.rb:1439:in `activate_dependencies'
        from /usr/share/rubygems/rubygems/specification.rb:1421:in `activate'
        from /usr/share/rubygems/rubygems.rb:286:in `block in activate_bin_path'
        from /usr/share/rubygems/rubygems.rb:285:in `synchronize'
        from /usr/share/rubygems/rubygems.rb:285:in `activate_bin_path'
        from /usr/share/vagrant/gems/bin/vagrant:25:in `<main>'
/usr/share/rubygems/rubygems/dependency.rb:311:in `to_specs': Could not find 'googleapis-common-protos-types' (~> 1.3) among 110 total gem(s) (Gem::MissingSpecError)
Checked in 'GEM_PATH=/usr/share/gems:/usr/share/vagrant/gems:/home/pclx/.vagrant.d/gems' , execute `gem env` for more information
        from /usr/share/rubygems/rubygems/specification.rb:1451:in `block in activate_dependencies'
        from /usr/share/rubygems/rubygems/specification.rb:1439:in `each'
        from /usr/share/rubygems/rubygems/specification.rb:1439:in `activate_dependencies'
        from /usr/share/rubygems/rubygems/specification.rb:1421:in `activate'
        from /usr/share/rubygems/rubygems.rb:286:in `block in activate_bin_path'
        from /usr/share/rubygems/rubygems.rb:285:in `synchronize'
        from /usr/share/rubygems/rubygems.rb:285:in `activate_bin_path'
        from /usr/share/vagrant/gems/bin/vagrant:25:in `<main>'
"""

Install the package "ruby-googleapis-common-protos-types" that contains that dependency, run "vagrant init" again and see the following error message:
"""
$ vagrant init
/usr/share/rubygems/rubygems/specification.rb:1453:in `rescue in block in activate_dependencies': Could not find 'grpc' (>= 0) among 112 total gem(s) (Gem::MissingSpecError)
Checked in 'GEM_PATH=/usr/share/gems:/usr/share/vagrant/gems:/home/pclx/.vagrant.d/gems' at: /usr/share/vagrant/gems/specifications/vagrant-2.3.7.gemspec, execute `gem env` for more information
        from /usr/share/rubygems/rubygems/specification.rb:1450:in `block in activate_dependencies'
        from /usr/share/rubygems/rubygems/specification.rb:1439:in `each'
        from /usr/share/rubygems/rubygems/specification.rb:1439:in `activate_dependencies'
        from /usr/share/rubygems/rubygems/specification.rb:1421:in `activate'
        from /usr/share/rubygems/rubygems.rb:286:in `block in activate_bin_path'
        from /usr/share/rubygems/rubygems.rb:285:in `synchronize'
        from /usr/share/rubygems/rubygems.rb:285:in `activate_bin_path'
        from /usr/share/vagrant/gems/bin/vagrant:25:in `<main>'
/usr/share/rubygems/rubygems/dependency.rb:311:in `to_specs': Could not find 'grpc' (>= 0) among 112 total gem(s) (Gem::MissingSpecError)
Checked in 'GEM_PATH=/usr/share/gems:/usr/share/vagrant/gems:/home/pclx/.vagrant.d/gems' , execute `gem env` for more information
        from /usr/share/rubygems/rubygems/specification.rb:1451:in `block in activate_dependencies'
        from /usr/share/rubygems/rubygems/specification.rb:1439:in `each'
        from /usr/share/rubygems/rubygems/specification.rb:1439:in `activate_dependencies'
        from /usr/share/rubygems/rubygems/specification.rb:1421:in `activate'
        from /usr/share/rubygems/rubygems.rb:286:in `block in activate_bin_path'
        from /usr/share/rubygems/rubygems.rb:285:in `synchronize'
        from /usr/share/rubygems/rubygems.rb:285:in `activate_bin_path'
        from /usr/share/vagrant/gems/bin/vagrant:25:in `<main>'
"""

Install the package "ruby-grpc" that contains that dependency, run "vagrant init" again and see the following error message:
"""
$ vagrant init
/usr/share/rubygems/rubygems/specification.rb:1453:in `rescue in block in activate_dependencies': Could not find 'rgl' (>= 0.5.10) among 113 total gem(s) (Gem::MissingSpecError)
Checked in 'GEM_PATH=/usr/share/gems:/usr/share/vagrant/gems:/home/pclx/.vagrant.d/gems' at: /usr/share/vagrant/gems/specifications/vagrant-2.3.7.gemspec, execute `gem env` for more information
        from /usr/share/rubygems/rubygems/specification.rb:1450:in `block in activate_dependencies'
        from /usr/share/rubygems/rubygems/specification.rb:1439:in `each'
        from /usr/share/rubygems/rubygems/specification.rb:1439:in `activate_dependencies'
        from /usr/share/rubygems/rubygems/specification.rb:1421:in `activate'
        from /usr/share/rubygems/rubygems.rb:286:in `block in activate_bin_path'
        from /usr/share/rubygems/rubygems.rb:285:in `synchronize'
        from /usr/share/rubygems/rubygems.rb:285:in `activate_bin_path'
        from /usr/share/vagrant/gems/bin/vagrant:25:in `<main>'
/usr/share/rubygems/rubygems/dependency.rb:311:in `to_specs': Could not find 'rgl' (>= 0.5.10) among 113 total gem(s) (Gem::MissingSpecError)
Checked in 'GEM_PATH=/usr/share/gems:/usr/share/vagrant/gems:/home/pclx/.vagrant.d/gems' , execute `gem env` for more information
        from /usr/share/rubygems/rubygems/specification.rb:1451:in `block in activate_dependencies'
        from /usr/share/rubygems/rubygems/specification.rb:1439:in `each'
        from /usr/share/rubygems/rubygems/specification.rb:1439:in `activate_dependencies'
        from /usr/share/rubygems/rubygems/specification.rb:1421:in `activate'
        from /usr/share/rubygems/rubygems.rb:286:in `block in activate_bin_path'
        from /usr/share/rubygems/rubygems.rb:285:in `synchronize'
        from /usr/share/rubygems/rubygems.rb:285:in `activate_bin_path'
        from /usr/share/vagrant/gems/bin/vagrant:25:in `<main>'
"""

Install the package "ruby-rgl" that contains that dependency, run "vagrant init" again and see the following error message:
"""
$ vagrant init
<internal:/usr/share/rubygems/rubygems/core_ext/kernel_require.rb>:85:in `require': cannot load such file -- vagrant_cloud (LoadError)
        from <internal:/usr/share/rubygems/rubygems/core_ext/kernel_require.rb>:85:in `require'
        from /usr/share/vagrant/gems/gems/vagrant-2.3.7/plugins/commands/cloud/plugin.rb:2:in `<top (required)>'
        from /usr/share/vagrant/gems/gems/vagrant-2.3.7/lib/vagrant.rb:344:in `load'
        from /usr/share/vagrant/gems/gems/vagrant-2.3.7/lib/vagrant.rb:344:in `block in <top (required)>'
        from /usr/share/vagrant/gems/gems/vagrant-2.3.7/lib/vagrant.rb:361:in `each'
        from /usr/share/vagrant/gems/gems/vagrant-2.3.7/lib/vagrant.rb:361:in `block in <top (required)>'
        from /usr/share/vagrant/gems/gems/vagrant-2.3.7/lib/vagrant.rb:353:in `each'
        from /usr/share/vagrant/gems/gems/vagrant-2.3.7/lib/vagrant.rb:353:in `<top (required)>'
        from <internal:/usr/share/rubygems/rubygems/core_ext/kernel_require.rb>:85:in `require'
        from <internal:/usr/share/rubygems/rubygems/core_ext/kernel_require.rb>:85:in `require'
        from /usr/share/vagrant/gems/gems/vagrant-2.3.7/bin/vagrant:111:in `<top (required)>'
        from /usr/share/vagrant/gems/bin/vagrant:25:in `load'
        from /usr/share/vagrant/gems/bin/vagrant:25:in `<main>'
"""

Install the package "ruby-vagrant_cloud" that contains that dependency, run "vagrant init" again and see the following message:
"""
$ vagrant init
A `Vagrantfile` has been placed in this directory. You are now
ready to `vagrant up` your first virtual environment! Please read
the comments in the Vagrantfile as well as documentation on
`vagrantup.com` for more information on using Vagrant.
"""

After this, vagrant is functional.

So, in summary the following dependencies are missing:
ruby-googleapis-common-protos-types
ruby-grpc
ruby-rgl
ruby-vagrant_cloud



Version-Release number of selected component (if applicable):

$ rpm -q vagrant vagrant-libvirt
vagrant-2.3.7-1.mga9
vagrant-libvirt-0.12.2-1.mga9
$ uname -a
Linux jupiter 6.6.22-desktop-1.mga9 #1 SMP PREEMPT_DYNAMIC Sun Mar 17 18:04:51 UTC 2024 x86_64 GNU/Linux



How reproducible:

Always.



Steps to Reproduce:
1. Install vagrant with command "urpmi --no-recommends vagrant"
2. Run vagrant in terminal/console with command "vagrant init"
3. See the error message indicating missing dependency.
4. Install the missing dependency.
5. Repeat steps 1 to 4 until all dependencies are installed and vagrant no longer outputs error messages.
Comment 1 Lewis Smith 2024-04-13 21:24:03 CEST
Thank you for this helpful report.

"So, in summary the following dependencies are missing:
 ruby-googleapis-common-protos-types    [required by the following pkg]
 ruby-grpc                              [requires the previous pkg]
 ruby-rgl
 ruby-vagrant_cloud"

$ urpmq --requires ruby-grpc | grep googleapis
 rubygem(googleapis-common-protos-types)[>= 1.0]
 rubygem(googleapis-common-protos-types)[< 2]

vagrant currently requires none of the cited dependencies, but most of its ruby dependencies ($ urpmq --requires vagrant | grep ruby) show as 'rubygem ...'. Is this significant?
Of the last 3, nothing currently requires them ($ urpmq --whatrequires xxx).
I think 'requires' for them by vagrant would sort it - including indirectly the first.

QA: just look at the vagrant package requires both ways re the missing dependencies. 

Different packagers commit vagrant, so assigning this globally.

Assignee: bugsquad => pkg-bugs