mitchellh/vagrant — Issue #697: Invalid date format causes error with simple installation on Oneric (plus a workaround)
Author: wamcvey
Created: 2012-01-31 16:49:30+00:00
State: open

On Ubuntu Oneiric (11.10), with rubygems (1.7.2-1) and ruby (1.8.7.352-2) installed from system debs, I get a fatal error when I do the simple "vagrant box add base" from the front-page quick start documentation. In particular, I get the following warning when I do the initial 'gem install vagrant':

Invalid gemspec in [/home/wam/lib/gems/specifications/json-1.5.4.gemspec]: invalid date format in specification: "2011-08-31 00:00:00.000000000Z"
Invalid gemspec in [/home/wam/lib/gems/specifications/json-1.5.4.gemspec]: invalid date format in specification: "2011-08-31 00:00:00.000000000Z"

The installation continues on though and vagrant successfully installs. However, when I run the installation for the base box, I get:

zelbinion ~/projs $ vagrant box add base http://files.vagrantup.com/lucid64.box
Invalid gemspec in [/home/wam/lib/gems/specifications/json-1.5.4.gemspec]: invalid date format in specification: "2011-08-31 00:00:00.000000000Z"
/usr/lib/ruby/vendor_ruby/1.8/rubygems/custom_require.rb:53:in `gem_original_require': no such file to load -- json (LoadError)
from /usr/lib/ruby/vendor_ruby/1.8/rubygems/custom_require.rb:53:in `require'
from /home/wam/lib/gems/gems/vagrant-0.9.4/lib/vagrant.rb:46
from /usr/lib/ruby/vendor_ruby/1.8/rubygems/custom_require.rb:53:in `gem_original_require'
from /usr/lib/ruby/vendor_ruby/1.8/rubygems/custom_require.rb:53:in `require'
from /home/wam/lib/gems/gems/vagrant-0.9.4/bin/vagrant:3
from /home/wam/lib/gems/bin/vagrant:19:in `load'
from /home/wam/lib/gems/bin/vagrant:19

And this is a full blown error that exits out of the program. Seeing that the problem seemed to an issue with the `json` gem, I went ahead and did 'gem install json' and it upgraded me from json-1.5.4 to json-1.5.5, which seems to work with vagrant (although I still get the 'invalid date format' warning, it no longer errors out). I figured you might want to document that people should consider upgrading the json gem on Ubuntu Oneric (otherwise, people might get the wrong idea about vagrant).