#36 Added missing dependency on rexml and mime-types
Merged 11 months ago by jackorp. Opened 11 months ago by zzambers.
rpms/ zzambers/vagrant vagrant-2.3.4-fix-deps  into  rawhide

file modified
+8 -1
@@ -7,7 +7,7 @@ 

  

  Name: vagrant

  Version: 2.3.4

- Release: 1%{?dist}

+ Release: 2%{?dist}

  Summary: Build and distribute virtualized development environments

  License: MIT

  URL: http://vagrantup.com
@@ -62,6 +62,8 @@ 

  Requires: rubygem(rest-client) >= 1.6.0

  Requires: rubygem(rubyzip) >= 1.1.7

  Requires: rubygem(net-ftp)

+ Requires: rubygem(rexml)

+ Requires: rubygem(mime-types)

  Requires: bsdtar

  Requires: curl

  Requires: %{_bindir}/ps
@@ -102,6 +104,8 @@ 

  BuildRequires: rubygem(fake_ftp)

  BuildRequires: rubygem(rake)

  BuildRequires: rubygem(net-ftp)

+ BuildRequires: rubygem(rexml)

+ BuildRequires: rubygem(mime-types)

  BuildRequires: pkgconfig(bash-completion)

  %if %{with help2man}

  BuildRequires: help2man
@@ -486,6 +490,9 @@ 

  %{vagrant_plugin_instdir}/vagrant-spec.config.example.rb

  

  %changelog

+ * Wed Jun 21 2023 Zdenek Zambersky <zzambers@redhat.com> - 2.3.4-2

+ - Added missing dependency on rexml and mime-types

+ 

  * Tue May 09 2023 Jarek Prokop <jprokop@redhat.com> - 2.3.4-1

  - Upgrade to Vagrant 2.3.4.

  

Adds dependency on rubygem(rexml) and also on rubygem(mime-types).

Details:
I have found that vagrant package in fedora rawhide has missing dependencies causing:

vagrant --version
/usr/share/rubygems/rubygems/specification.rb:1458:in `rescue in block in activate_dependencies': Could not find 'rexml' (~> 3.2) among 103 total gem(s) (Gem::MissingSpecError)
Checked in 'GEM_PATH=/usr/share/gems:/usr/share/vagrant/gems:/home/tester/.vagrant.d/gems' at: /usr/share/vagrant/gems/specifications/vagrant-2.3.4.gemspec, execute `gem env` for more information
    from /usr/share/rubygems/rubygems/specification.rb:1455:in `block in activate_dependencies'
    from /usr/share/rubygems/rubygems/specification.rb:1444:in `each'
    from /usr/share/rubygems/rubygems/specification.rb:1444:in `activate_dependencies'
    from /usr/share/rubygems/rubygems/specification.rb:1426:in `activate'
    from /usr/share/rubygems/rubygems.rb:284:in `block in activate_bin_path'
    from /usr/share/rubygems/rubygems.rb:283:in `synchronize'
    from /usr/share/rubygems/rubygems.rb:283:in `activate_bin_path'
    from /usr/share/vagrant/gems/bin/vagrant:25:in `<main>'
/usr/share/rubygems/rubygems/dependency.rb:314:in `to_specs': Could not find 'rexml' (~> 3.2) among 103 total gem(s) (Gem::MissingSpecError)
Checked in 'GEM_PATH=/usr/share/gems:/usr/share/vagrant/gems:/home/tester/.vagrant.d/gems' , execute `gem env` for more information
    from /usr/share/rubygems/rubygems/specification.rb:1456:in `block in activate_dependencies'
    from /usr/share/rubygems/rubygems/specification.rb:1444:in `each'
    from /usr/share/rubygems/rubygems/specification.rb:1444:in `activate_dependencies'
    from /usr/share/rubygems/rubygems/specification.rb:1426:in `activate'
    from /usr/share/rubygems/rubygems.rb:284:in `block in activate_bin_path'
    from /usr/share/rubygems/rubygems.rb:283:in `synchronize'
    from /usr/share/rubygems/rubygems.rb:283:in `activate_bin_path'
    from /usr/share/vagrant/gems/bin/vagrant:25:in `<main>'

(installing rubygem-rexml fixes this)

Not sure why it was not caught by build or by me when testing 2.3.4 build. (maybe it used to be satisfied by transitive deps? Also vagrant-libvirt installs rubygem-rexml)

I went through dependencies and found that rubygem-mime-types is also missing, though currently seems to be satisfied by transitive deps.

I see, I think that when installing, we either usually expect users to do dnf install @vagrant or dnf install vagrant-libvirt which usually pulls necessary things.

I am able to reproduce in a Fedora rawhide container running dnf install vagrant and dnf install vagrant rubygem-rexml fixes it.
I vaguely that when weak deps are disabled, not everything works 100% as we might want it to.

This is a sanity check that has to be caught better on our side.

Both gems are expected in vagrant's gemspec, therefore it is better to list them as requires.

LGTM, thanks.

Pull-Request has been merged by jackorp

11 months ago

@zzambers seeing your recent contributions, would you like to become vagrant co-maintainer or are the contributions via PR good enough ATM?

@vondruch I think contributions via PR are ok for me, I currently don't have any more contributions to vagrant. Thanks

Metadata