Is this a bug in Rails? undefined method `change' for Infinity:Float (NoMethodError)

OS=CentOS-6.4
Ruby=ruby 1.9.3p286
Rails=bundler/lib/ruby/1.9.1/gems/rails-3.2.12

I am upgrading an RoR application from 3.1.1 running with Ruby-1.8.7 to RoR-3.2.12 running with Ruby-1.9.3. The version running with 3.1.1 passes all tests. The 3.2.12 is throwing this exception:

  undefined method `change' for Infinity:Float (NoMethodError)
  /home/byrnejb/Projects/Software/theHeart/code/proforma_rails_3_2/libexec/bundler/lib/ruby/1.9.1/gems/activerecord-3.2.12/lib/active_record/attribute_methods/time_zone_conversion.rb:69:in `round_usec'
  /home/byrnejb/Projects/Software/theHeart/code/proforma_rails_3_2/libexec/bundler/lib/ruby/1.9.1/gems/activerecord-3.2.12/lib/active_record/attribute_methods/time_zone_conversion.rb:46:in `expected_at='
  /home/byrnejb/Projects/Software/theHeart/code/proforma_rails_3_2/features/app/models/ca_customs_shipments/step_definitions/ca_customs_shipment_steps.rb:95:in `block in <top (required)>'

The piece of test code that is failing is this:

ship.expected_at = rand( 3 * 24 * 60 * 60 ).seconds.from_now

What has changed?

Can you try with 3.2.13.rc2?

Certainly. where do I get it? Or I should ask, what do I put in my Gemfile that will find it?

Use that exact version: 3.2.13.rc2, and run bundle update rails. It’s a release candidate of the next version, for people to test it out and see if they don’t find regressions.

I already tried that, without success:

$ bundle update
Fetching gem metadata from https://rubygems.org/
Fetching gem metadata from https://rubygems.org/
Resolving dependencies…
Could not find gem 'rails (= 3.2.12.rc2) ruby' in the gems available
on this machine.

$ bundle install
Fetching gem metadata from https://rubygems.org/
Fetching gem metadata from https://rubygems.org/
Resolving dependencies…
Could not find gem 'rails (= 3.2.12.rc2) ruby' in the gems available
on this machine.

Never mind, I see that I wrote 12 when I meant 13.

Bundler could not find compatible versions for gem "i18n":
  In Gemfile:
    rails (= 3.2.13.rc2) ruby depends on
      i18n (= 0.6.1) ruby

     i18n (0.6.4)

Unfortunately, I have another dependency that requires I18n (0.6.4) so
downgrading is not an option I am prepared to consider. Is there some
reason that RoR-3.2.12 works with 0.6.4 and 3.2.13 does not?

There was a problem with i18n versions, so someone locked it to 0.6.1 before releasing the first rc =(. It’s already fixed but the rc is locked and probably 3.2.13 will be, need to check that.

I extracted the bits of interest and tested them against ror-3.2.13rc2. The test now passes. So, I will roll this back into the project and go on from there.

Alright, great to know that was fixed in 3.2.13.rc :). I’ll check what we can do regarding i18n. Thanks!