Join GitHub today
GitHub is home to over 20 million developers working together to host and review code, manage projects, and build software together.
ActiveSupport::Timezone resets the timezone when calling round on the time #12596
Let us say we have a time object of ActiveSupport::Timezone with the time set to the 1 hour transition period while switching from DST to normal time. When round method is called on that time, the timezone switches back to DST from non-DST. Following example illustrates the behaviour.
I first thought it may be a Time.round bug and submitted to ruby-core. But looks like it must be ActiveSupport::Timezone issues.