Lighthouse has a new layout. Prefer the old one? Return to the old layout, and switch back any time from the link at the top of each page.

This project is archived and is in readonly mode.

Date bug in rails 3

#6237

Hi, i just found this bug, it seems that it won't reconize 30. December in Rails 3.0.1.

>> Date.today
=> Fri, 31 Dec 2010
>> Date.yesterday
=> Wed, 29 Dec 2010
I'm using ruby version ruby 1.8.7

Update.

It looks like that it was until 0.59..

Reported by Oluf Nielsen · December 31st, 2010 @ 12:03 AM

State: duplicate
Milestone: none
Assigned to: nobody
Importance: Low

Activity

  1. ninajansen
    ninajansen

    Same problem in rails 3.0.3, ruby 1.8.7

    December 31st, 2010 @ 12:08 AM

  2. esparkman
    esparkman

    I am unable to reproduce this with Ruby 1.8.7-p330 and Rails 3.0.1.

    December 31st, 2010 @ 12:32 AM

  3. ninajansen
    ninajansen

    I'm on rails 3.0.3, ruby 1.8.7-p302, the bug only occurred in the first hour of the day, i.e. from 00:00 to 00:59

    December 31st, 2010 @ 12:37 AM

  4. esparkman
    esparkman

    Loading development environment (Rails 3.0.1)
    ruby-1.8.7-p330 :001 > Date.today
    => Fri, 31 Dec 2010 ruby-1.8.7-p330 :002 > Date.yesterday
    => Thu, 30 Dec 2010 ruby-1.8.7-p330 :003 >

    That is what I got my system time is set to 12:40AM

    December 31st, 2010 @ 12:41 AM

  5. Oluf Nielsen
    Oluf Nielsen

    I'm using the 24h system, and when i take it to 0.45 on my mac ( 1 hour back ) it gives me this

    >> Date.today
    => Fri, 31 Dec 2010
    >> Date.yesterday
    => Wed, 29 Dec 2010
    

    it looks like this in my terminal with the time set back..
    https://skitch.com/olufnielsen/r8gqs/systemuiserver

    December 31st, 2010 @ 12:46 AM

  6. Utkarsh Kukreti
  7. Rohit Arondekar
    Rohit Arondekar
    • State changed from new to duplicate
    • Importance changed from to Low

    January 2nd, 2011 @ 12:59 AM

  8. bingbing