hashicorp / vagrant

Vagrant is a tool for building and distributing development environments.
https://www.vagrantup.com
Other
26.18k stars 4.43k forks source link

Cannot install any plugin on Archlinux #13476

Open arcenik opened 1 month ago

arcenik commented 1 month ago

I've tried to install vagrant-libvirt, vagrant-vbguest and vagrant-env with the same error

Expected behavior

The plugin installation should work

To Reproduce

$ vagrant plugin install vagrant-libvirt
Installing the 'vagrant-libvirt' plugin. This can take a few minutes...
/usr/lib/ruby/3.0.0/rubygems/resolver/conflict.rb:47:in `conflicting_dependencies': undefined method `request' for nil:NilClass (NoMethodError)
        from /usr/lib/ruby/3.0.0/rubygems/exceptions.rb:61:in `conflicting_dependencies'
        from /usr/lib/ruby/3.0.0/rubygems/exceptions.rb:55:in `initialize'
        from /usr/lib/ruby/3.0.0/rubygems/resolver.rb:193:in `exception'
        from /usr/lib/ruby/3.0.0/rubygems/resolver.rb:193:in `raise'
        from /usr/lib/ruby/3.0.0/rubygems/resolver.rb:193:in `rescue in resolve'
        from /usr/lib/ruby/3.0.0/rubygems/resolver.rb:191:in `resolve'
        from /usr/lib/ruby/3.0.0/rubygems/request_set.rb:411:in `resolve'
        from /opt/vagrant/embedded/gems/gems/vagrant-2.4.1/lib/vagrant/bundler.rb:604:in `internal_install'
        from /opt/vagrant/embedded/gems/gems/vagrant-2.4.1/lib/vagrant/bundler.rb:358:in `install'
        from /opt/vagrant/embedded/gems/gems/vagrant-2.4.1/lib/vagrant/plugin/manager.rb:141:in `block in install_plugin'
        from /opt/vagrant/embedded/gems/gems/vagrant-2.4.1/lib/vagrant/plugin/manager.rb:151:in `install_plugin'
        from /opt/vagrant/embedded/gems/gems/vagrant-2.4.1/plugins/commands/plugin/action/install_gem.rb:33:in `call'
        from /opt/vagrant/embedded/gems/gems/vagrant-2.4.1/lib/vagrant/action/warden.rb:38:in `call'
        from /opt/vagrant/embedded/gems/gems/vagrant-2.4.1/lib/vagrant/action/builder.rb:183:in `call'
        from /opt/vagrant/embedded/gems/gems/vagrant-2.4.1/lib/vagrant/action/runner.rb:104:in `block in run'
        from /opt/vagrant/embedded/gems/gems/vagrant-2.4.1/lib/vagrant/util/busy.rb:22:in `busy'
        from /opt/vagrant/embedded/gems/gems/vagrant-2.4.1/lib/vagrant/action/runner.rb:104:in `run'
        from /opt/vagrant/embedded/gems/gems/vagrant-2.4.1/plugins/commands/plugin/command/base.rb:17:in `action'
        from /opt/vagrant/embedded/gems/gems/vagrant-2.4.1/plugins/commands/plugin/command/install.rb:73:in `block in execute'
        from /opt/vagrant/embedded/gems/gems/vagrant-2.4.1/plugins/commands/plugin/command/install.rb:72:in `each'
        from /opt/vagrant/embedded/gems/gems/vagrant-2.4.1/plugins/commands/plugin/command/install.rb:72:in `execute'
        from /opt/vagrant/embedded/gems/gems/vagrant-2.4.1/plugins/commands/plugin/command/root.rb:69:in `execute'
        from /opt/vagrant/embedded/gems/gems/vagrant-2.4.1/lib/vagrant/cli.rb:67:in `execute'
        from /opt/vagrant/embedded/gems/gems/vagrant-2.4.1/lib/vagrant/environment.rb:319:in `cli'
        from /opt/vagrant/embedded/gems/gems/vagrant-2.4.1/bin/vagrant:248:in `<main>'
/usr/lib/ruby/3.0.0/rubygems/resolver/molinillo/lib/molinillo/resolution.rb:317:in `raise_error_unless_state': Unable to satisfy the following requirements: (Gem::Resolver::Molinillo::VersionConflict)

- `facter (= 3.14.24)` required by `user-specified dependency`
- `facter (> 2.0.1, < 5)` required by `puppet-7.31.0`
        from /usr/lib/ruby/3.0.0/rubygems/resolver/molinillo/lib/molinillo/resolution.rb:299:in `block in unwind_for_conflict'
        from <internal:kernel>:90:in `tap'
        from /usr/lib/ruby/3.0.0/rubygems/resolver/molinillo/lib/molinillo/resolution.rb:297:in `unwind_for_conflict'
        from /usr/lib/ruby/3.0.0/rubygems/resolver/molinillo/lib/molinillo/resolution.rb:682:in `attempt_to_activate'
        from /usr/lib/ruby/3.0.0/rubygems/resolver/molinillo/lib/molinillo/resolution.rb:254:in `process_topmost_state'
        from /usr/lib/ruby/3.0.0/rubygems/resolver/molinillo/lib/molinillo/resolution.rb:182:in `resolve'
        from /usr/lib/ruby/3.0.0/rubygems/resolver/molinillo/lib/molinillo/resolver.rb:43:in `resolve'
        from /usr/lib/ruby/3.0.0/rubygems/resolver.rb:190:in `resolve'
        from /usr/lib/ruby/3.0.0/rubygems/request_set.rb:411:in `resolve'
        from /opt/vagrant/embedded/gems/gems/vagrant-2.4.1/lib/vagrant/bundler.rb:604:in `internal_install'
        from /opt/vagrant/embedded/gems/gems/vagrant-2.4.1/lib/vagrant/bundler.rb:358:in `install'
        from /opt/vagrant/embedded/gems/gems/vagrant-2.4.1/lib/vagrant/plugin/manager.rb:141:in `block in install_plugin'
        from /opt/vagrant/embedded/gems/gems/vagrant-2.4.1/lib/vagrant/plugin/manager.rb:151:in `install_plugin'
        from /opt/vagrant/embedded/gems/gems/vagrant-2.4.1/plugins/commands/plugin/action/install_gem.rb:33:in `call'
        from /opt/vagrant/embedded/gems/gems/vagrant-2.4.1/lib/vagrant/action/warden.rb:38:in `call'
        from /opt/vagrant/embedded/gems/gems/vagrant-2.4.1/lib/vagrant/action/builder.rb:183:in `call'
        from /opt/vagrant/embedded/gems/gems/vagrant-2.4.1/lib/vagrant/action/runner.rb:104:in `block in run'
        from /opt/vagrant/embedded/gems/gems/vagrant-2.4.1/lib/vagrant/util/busy.rb:22:in `busy'
        from /opt/vagrant/embedded/gems/gems/vagrant-2.4.1/lib/vagrant/action/runner.rb:104:in `run'
        from /opt/vagrant/embedded/gems/gems/vagrant-2.4.1/plugins/commands/plugin/command/base.rb:17:in `action'
        from /opt/vagrant/embedded/gems/gems/vagrant-2.4.1/plugins/commands/plugin/command/install.rb:73:in `block in execute'
        from /opt/vagrant/embedded/gems/gems/vagrant-2.4.1/plugins/commands/plugin/command/install.rb:72:in `each'
        from /opt/vagrant/embedded/gems/gems/vagrant-2.4.1/plugins/commands/plugin/command/install.rb:72:in `execute'
        from /opt/vagrant/embedded/gems/gems/vagrant-2.4.1/plugins/commands/plugin/command/root.rb:69:in `execute'
        from /opt/vagrant/embedded/gems/gems/vagrant-2.4.1/lib/vagrant/cli.rb:67:in `execute'
        from /opt/vagrant/embedded/gems/gems/vagrant-2.4.1/lib/vagrant/environment.rb:319:in `cli'
        from /opt/vagrant/embedded/gems/gems/vagrant-2.4.1/bin/vagrant:248:in `<main>'

Debug output

vagrant-libvirt-install.log

Vagrant version

$vagrant version
Installed Version: 2.4.1
Latest Version: 2.4.1

You're running an up-to-date version of Vagrant!

Host operating system

Archlinux

arcenik commented 1 month ago

To make is work, I had to uninstall puppet and facter and use a work arround for date gem version conflict (as explained here https://bbs.archlinux.org/viewtopic.php?id=292146 ) but now I have another problem with google-protobuf version that is included in the Vagrant package.

$ sudo pacman -R facter puppet --noconfirm
checking dependencies...

Package (2)  Old Version  Net Change

facter       3.14.24-7     -1.68 MiB
puppet       7.31.0-2      -5.76 MiB

$ vagrant plugin install vagrant-share
Installing the 'vagrant-share' plugin. This can take a few minutes...
Vagrant failed to properly resolve required dependencies. These
errors can commonly be caused by misconfigured plugin installations
or transient network issues. The reported error is:

conflicting dependencies date (= 3.2.2) and date (= 3.3.4)
  Activated date-3.3.4
  which does not match conflicting dependency (= 3.2.2)

  Conflicting dependency chains:
    date (= 3.3.4), 3.3.4 activated

  versus:
    date (= 3.2.2)

  Gems matching date (= 3.2.2):
    date-3.2.2

$ VAGRANT_DISABLE_STRICT_DEPENDENCY_ENFORCEMENT=1 vagrant plugin install vagrant-share
Installing the 'vagrant-share' plugin. This can take a few minutes...
/usr/lib/ruby/3.0.0/rubygems/specification.rb:2278:in `check_version_conflict': can't activate google-protobuf-3.25.3-x86_64-linux, already activated google-protobuf-3.25.2-x86_64-linux (Gem::LoadError)
        from /usr/lib/ruby/3.0.0/rubygems/specification.rb:1415:in `activate'
        from /opt/vagrant/embedded/gems/gems/vagrant-2.4.1/lib/vagrant/bundler.rb:769:in `block in activate_solution'
        from /opt/vagrant/embedded/gems/gems/vagrant-2.4.1/lib/vagrant/bundler.rb:766:in `each'
        from /opt/vagrant/embedded/gems/gems/vagrant-2.4.1/lib/vagrant/bundler.rb:766:in `activate_solution'
        from /opt/vagrant/embedded/gems/gems/vagrant-2.4.1/lib/vagrant/bundler.rb:606:in `internal_install'
        from /opt/vagrant/embedded/gems/gems/vagrant-2.4.1/lib/vagrant/bundler.rb:358:in `install'
        from /opt/vagrant/embedded/gems/gems/vagrant-2.4.1/lib/vagrant/plugin/manager.rb:141:in `block in install_plugin'
        from /opt/vagrant/embedded/gems/gems/vagrant-2.4.1/lib/vagrant/plugin/manager.rb:151:in `install_plugin'
        from /opt/vagrant/embedded/gems/gems/vagrant-2.4.1/plugins/commands/plugin/action/install_gem.rb:33:in `call'
        from /opt/vagrant/embedded/gems/gems/vagrant-2.4.1/lib/vagrant/action/warden.rb:38:in `call'
        from /opt/vagrant/embedded/gems/gems/vagrant-2.4.1/lib/vagrant/action/builder.rb:183:in `call'
        from /opt/vagrant/embedded/gems/gems/vagrant-2.4.1/lib/vagrant/action/runner.rb:104:in `block in run'
        from /opt/vagrant/embedded/gems/gems/vagrant-2.4.1/lib/vagrant/util/busy.rb:22:in `busy'
        from /opt/vagrant/embedded/gems/gems/vagrant-2.4.1/lib/vagrant/action/runner.rb:104:in `run'
        from /opt/vagrant/embedded/gems/gems/vagrant-2.4.1/plugins/commands/plugin/command/base.rb:17:in `action'
        from /opt/vagrant/embedded/gems/gems/vagrant-2.4.1/plugins/commands/plugin/command/install.rb:73:in `block in execute'
        from /opt/vagrant/embedded/gems/gems/vagrant-2.4.1/plugins/commands/plugin/command/install.rb:72:in `each'
        from /opt/vagrant/embedded/gems/gems/vagrant-2.4.1/plugins/commands/plugin/command/install.rb:72:in `execute'
        from /opt/vagrant/embedded/gems/gems/vagrant-2.4.1/plugins/commands/plugin/command/root.rb:69:in `execute'
        from /opt/vagrant/embedded/gems/gems/vagrant-2.4.1/lib/vagrant/cli.rb:67:in `execute'
        from /opt/vagrant/embedded/gems/gems/vagrant-2.4.1/lib/vagrant/environment.rb:319:in `cli'
        from /opt/vagrant/embedded/gems/gems/vagrant-2.4.1/bin/vagrant:248:in `<main>'