Be a bit more fine grained about errors that are reported for Vfiles
This commit is contained in:
parent
67c2e205be
commit
a8c7ad30ee
|
@ -200,6 +200,13 @@ module Vagrant
|
||||||
rescue SyntaxError => e
|
rescue SyntaxError => e
|
||||||
# Report syntax errors in a nice way.
|
# Report syntax errors in a nice way.
|
||||||
raise Errors::VagrantfileSyntaxError, :file => e.message
|
raise Errors::VagrantfileSyntaxError, :file => e.message
|
||||||
|
rescue SystemExit
|
||||||
|
# Continue raising that exception...
|
||||||
|
raise
|
||||||
|
rescue Vagrant::Errors::VagrantError
|
||||||
|
# Continue raising known Vagrant errors since they already
|
||||||
|
# contain well worded error messages and context.
|
||||||
|
raise
|
||||||
rescue Exception => e
|
rescue Exception => e
|
||||||
@logger.error("Vagrantfile load error: #{e.message}")
|
@logger.error("Vagrantfile load error: #{e.message}")
|
||||||
@logger.error(e.backtrace.join("\n"))
|
@logger.error(e.backtrace.join("\n"))
|
||||||
|
|
Loading…
Reference in New Issue