** Description changed: + [Impact] + + This issue is not critical but I believe it degrades a lot the user + experience in a brand new LTS release. Every time one calls vagrant via + CLI, Ruby 2.7 throws a bunch of warnings about some deprecated features, + which for some (inexperienced?) users might seem a failure in a first + look. + + This was reported not just here as a bug report but also in Discourse: + + https://discourse.ubuntu.com/t/workarounds-for-applications-which-are- + broken-in-20-04lts/15474/5 + + [Test Case] + + In a Focal LXD container: + + $ apt install vagrant + $ vagrant + NOTE: Gem::Specification.default_specifications_dir is deprecated; use Gem.default_specifications_dir instead. It will be removed on or after 2020-02-01. + Gem::Specification.default_specifications_dir called from /usr/share/rubygems-integration/all/gems/vagrant-2.2.6/lib/vagrant/bundler.rb:428. + /usr/share/rubygems-integration/all/gems/vagrant-2.2.6/lib/vagrant/errors.rb:103: warning: Using the last argument as keyword parameters is deprecated; maybe ** should be added to the call + /usr/share/rubygems-integration/all/gems/i18n-1.8.2/lib/i18n.rb:195: warning: The called method `t' is defined here + (eval):3: warning: Using the last argument as keyword parameters is deprecated; maybe ** should be added to the call + /usr/share/rubygems-integration/all/gems/vagrant-2.2.6/lib/vagrant/ui.rb:223: warning: The called method `say' is defined here + Usage: vagrant [options] <command> [<args>] + + -v, --version Print the version and exit. + -h, --help Print this help. + + Common commands: + box manages boxes: installation, removal, etc. + cloud manages everything related to Vagrant Cloud + destroy stops and deletes all traces of the vagrant machine + global-status outputs status Vagrant environments for this user + halt stops the vagrant machine + help shows the help for a subcommand + init initializes a new Vagrant environment by creating a Vagrantfile + login + package packages a running vagrant environment into a box + plugin manages plugins: install, uninstall, update, etc. + port displays information about guest port mappings + powershell connects to machine via powershell remoting + provision provisions the vagrant machine + push deploys code in this environment to a configured destination + rdp connects to machine via RDP + reload restarts vagrant machine, loads new Vagrantfile configuration + resume resume a suspended vagrant machine + snapshot manages snapshots: saving, restoring, etc. + ssh connects to machine via SSH + ssh-config outputs OpenSSH valid configuration to connect to the machine + status outputs status of the vagrant machine + suspend suspends the machine + up starts and provisions the vagrant environment + upload upload to machine via communicator + validate validates the Vagrantfile + version prints current and latest Vagrant version + winrm executes commands on a machine via WinRM + winrm-config outputs WinRM configuration to connect to the machine + + For help on any individual command run `vagrant COMMAND -h` + + Additional subcommands are available, but are either more advanced + or not commonly used. To see all subcommands, run the command + `vagrant list-commands`. + $ vagrant init + NOTE: Gem::Specification.default_specifications_dir is deprecated; use Gem.default_specifications_dir instead. It will be removed on or after 2020-02-01. + Gem::Specification.default_specifications_dir called from /usr/share/rubygems-integration/all/gems/vagrant-2.2.6/lib/vagrant/bundler.rb:428. + /usr/share/rubygems-integration/all/gems/vagrant-2.2.6/lib/vagrant/errors.rb:103: warning: Using the last argument as keyword parameters is deprecated; maybe ** should be added to the call + /usr/share/rubygems-integration/all/gems/i18n-1.8.2/lib/i18n.rb:195: warning: The called method `t' is defined here + (eval):3: warning: Using the last argument as keyword parameters is deprecated; maybe ** should be added to the call + /usr/share/rubygems-integration/all/gems/vagrant-2.2.6/lib/vagrant/ui.rb:223: warning: The called method `say' is defined here + 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. + + + [Regression Potential] + + I consider the potential for a regression low, the patches are working + fine in Debian and they fix simple deprecated features in Ruby 2.7 + (Using the last argument as keyword parameters is deprecated; maybe ** + should be added to the call). The proposed changes were already applied + in multiple Ruby packages to fix the same issue, even upstream. However, + those patches were backported to vagrant 2.2.6 from Debian which has + vagrant version 2.2.7, so this might make room for some mistake. + + + + ==== Original description ==== + When calling vagrant subcommands, or just vagrant itself without any argument to produce help output, every time the following block of ruby warnings appears: $ vagrant NOTE: Gem::Specification.default_specifications_dir is deprecated; use Gem.default_specifications_dir instead. It will be removed on or after 2020-02-01. Gem::Specification.default_specifications_dir called from /usr/share/rubygems-integration/all/gems/vagrant-2.2.6/lib/vagrant/bundler.rb:428. NOTE: Gem::Specification.default_specifications_dir is deprecated; use Gem.default_specifications_dir instead. It will be removed on or after 2020-02-01. Gem::Specification.default_specifications_dir called from /usr/share/rubygems-integration/all/gems/vagrant-2.2.6/lib/vagrant/bundler.rb:428. /usr/share/rubygems-integration/all/gems/vagrant-2.2.6/lib/vagrant/errors.rb:103: warning: Using the last argument as keyword parameters is deprecated; maybe ** should be added to the call /usr/share/rubygems-integration/all/gems/i18n-1.8.2/lib/i18n.rb:195: warning: The called method `t' is defined here /usr/share/rubygems-integration/all/gems/vagrant-2.2.6/plugins/kernel_v2/config/vm.rb:354: warning: Using the last argument as keyword parameters is deprecated; maybe ** should be added to the call /usr/share/rubygems-integration/all/gems/vagrant-2.2.6/plugins/kernel_v2/config/vm_provisioner.rb:92: warning: The called method `add_config' is defined here (eval):3: warning: Using the last argument as keyword parameters is deprecated; maybe ** should be added to the call /usr/share/rubygems-integration/all/gems/vagrant-2.2.6/lib/vagrant/ui.rb:223: warning: The called method `say' is defined here [... actual output starts here ...] ProblemType: Bug DistroRelease: Ubuntu 20.04 Package: vagrant 2.2.6+dfsg-2ubuntu1 ProcVersionSignature: Ubuntu 5.4.0-21.25-generic 5.4.27 Uname: Linux 5.4.0-21-generic x86_64 NonfreeKernelModules: nvidia_modeset nvidia ApportVersion: 2.20.11-0ubuntu25 Architecture: amd64 CurrentDesktop: MATE Date: Wed Apr 8 20:20:25 2020 InstallationDate: Installed on 2020-04-06 (2 days ago) InstallationMedia: Ubuntu-Server 20.04 LTS "Focal Fossa" - Beta amd64 (20200402) PackageArchitecture: all ProcEnviron: - TERM=xterm-256color - PATH=(custom, no user) - LANG=C.UTF-8 - SHELL=/bin/bash + TERM=xterm-256color + PATH=(custom, no user) + LANG=C.UTF-8 + SHELL=/bin/bash SourcePackage: vagrant UpgradeStatus: No upgrade log present (probably fresh install)
** Tags added: verification-needed-focal ** Tags added: verification-needed ** Changed in: vagrant (Ubuntu) Status: Confirmed => In Progress ** Summary changed: - vagrant spits out ruby deprecation warnings on every call + [SRU] vagrant spits out ruby deprecation warnings on every call -- You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. https://bugs.launchpad.net/bugs/1871685 Title: [SRU] vagrant spits out ruby deprecation warnings on every call To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/vagrant/+bug/1871685/+subscriptions -- ubuntu-bugs mailing list ubuntu-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs