Project

General

Profile

Actions

Defect #2149

closed

Git Adapter date parsing ignores timezone

Added by Kevin Chan over 15 years ago. Updated over 15 years ago.

Status:
Closed
Priority:
High
Assignee:
-
Category:
SCM
Target version:
Start date:
2008-11-08
Due date:
% Done:

0%

Estimated time:
Resolution:
Fixed
Affected version:

Description

Git adapter uses Time.parse() on the date string, in the format Sat Nov 8 02:20:44 2008 -0800

TIme.parse() is unable to parse the timezone in the above date correctly:

in irb:

>> Time.parse("Sat Nov 8 02:20:44 2008 -0800")
=> Sat Nov 08 02:20:44 -0600 2008

The correct output should be the following (notice the placement of the year segment)

>> Time.parse("Sat Nov 8 2008 02:20:44 -0800")
=> Sat Nov 08 04:20:44 -0600 2008

This is causing a major issue with the repository to have incorrect times.

Actions

Also available in: Atom PDF