{"record":{"id":"b80242d0ef313346","repo":"hashicorp/vagrant","slug":"the-command-vagrant-name-has-been-deprecated","errorCode":null,"errorMessage":"The command 'vagrant %{name}' has been deprecated and is no longer functional\nwithin Vagrant.","messagePattern":"The command 'vagrant %(.+?)' has been deprecated and is no longer functional\nwithin Vagrant\\.","errorType":"exception","errorClass":"Vagrant::Errors::CommandDeprecated","httpStatus":null,"severity":"warning","filePath":"lib/vagrant/util/command_deprecation.rb","lineNumber":51,"sourceCode":"          alias_method :non_deprecated_execute, :execute\n\n          def execute(*args, &block)\n            @env[:ui].warn(I18n.t(\"vagrant.commands.deprecated\",\n              name: deprecation_command_name\n            ) + \"\\n\")\n            non_deprecated_execute(*args, &block)\n          end\n        end\n      end\n\n      # Mark command deprecation complete and fully disable\n      # the command's functionality\n      module Complete\n        def self.included(klass)\n          klass.include(CommandDeprecation)\n          klass.class_eval do\n            def execute(*_)\n              raise Vagrant::Errors::CommandDeprecated,\n                name: deprecation_command_name\n            end\n          end\n        end\n      end\n    end\n  end\nend\n","sourceCodeStart":33,"sourceCodeEnd":60,"githubUrl":"https://github.com/hashicorp/vagrant/blob/35f3160f4ad6edc3a9f3aa9570adfc1a4d73aaa5/lib/vagrant/util/command_deprecation.rb#L33-L60","documentation":"Raised by CLI command classes that include Vagrant::Util::CommandDeprecation::Complete: the module overrides #execute to immediately raise Errors::CommandDeprecated with deprecation_command_name. 'Complete' means the deprecation window has ended and the command's functionality is fully removed — it raises instead of running. The in-repo consumer is the legacy Atlas push (plugins/pushes/atlas/push.rb).","triggerScenarios":"Executing a retired command whose class mixes in CommandDeprecation::Complete — e.g. `vagrant push` with the legacy atlas strategy after Atlas-era push support was removed; also any third-party plugin command that includes the Complete module.","commonSituations":"Old scripts, CI pipelines, or docs still invoking commands that a Vagrant upgrade removed; muscle-muscle invocations after updating.","solutions":["Replace the invocation with the supported successor workflow (for box publication: `vagrant cloud publish`; for deploys: your own deploy tooling)","Audit scripts and docs for the retired command name and remove the calls","As a last resort, pin the last Vagrant version where the command still functioned while you migrate"],"exampleFix":"# before (retired command)\nvagrant push\n\n# after (publish box artifacts to Vagrant Cloud instead)\nvagrant cloud publish myuser/mybox 1.0.0 virtualbox box.box --short-description \"1.0.0\" --release","handlingStrategy":"fallback","validationCode":"# fail fast in scripts: only call commands that still exist\nlisted = `vagrant list-commands`.split\nfail 'vagrant push was removed' unless listed.include?('push')","typeGuard":null,"tryCatchPattern":"begin\n  Vagrant.application.execute('push')\nrescue Vagrant::Errors::CommandDeprecated => e\n  warn e.message\n  replacement_workflow # e.g. `vagrant cloud publish`\nend","preventionTips":["Check release notes for removed commands before upgrading Vagrant","Prefer long-lived stable commands in CI scripts","Wrap retired invocations in a shim that maps old names to new workflows"],"tags":["deprecation","cli","breaking-change","command-removed"],"backgroundTag":"deprecated-command-removed","analyzedSha":"35f3160f4ad6edc3a9f3aa9570adfc1a4d73aaa5","analyzedAt":"2026-08-21T13:34:32.514Z","schemaVersion":2},"datasetVersion":"2026-08-21T18:17:14.833Z"}