{"action":"created","issue":{"url":"https://api.github.com/repos/go-yaml/yaml/issues/82","labels_url":"https://api.github.com/repos/go-yaml/yaml/issues/82/labels{/name}","comments_url":"https://api.github.com/repos/go-yaml/yaml/issues/82/comments","events_url":"https://api.github.com/repos/go-yaml/yaml/issues/82/events","html_url":"https://github.com/go-yaml/yaml/issues/82","id":57914482,"number":82,"title":"Handling of time.Time is not symmetrical","user":{"login":"tchap","id":697127,"avatar_url":"https://avatars.githubusercontent.com/u/697127?v=3","gravatar_id":"","url":"https://api.github.com/users/tchap","html_url":"https://github.com/tchap","followers_url":"https://api.github.com/users/tchap/followers","following_url":"https://api.github.com/users/tchap/following{/other_user}","gists_url":"https://api.github.com/users/tchap/gists{/gist_id}","starred_url":"https://api.github.com/users/tchap/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tchap/subscriptions","organizations_url":"https://api.github.com/users/tchap/orgs","repos_url":"https://api.github.com/users/tchap/repos","events_url":"https://api.github.com/users/tchap/events{/privacy}","received_events_url":"https://api.github.com/users/tchap/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":5,"created_at":"2015-02-17T11:45:14Z","updated_at":"2015-02-24T22:47:37Z","closed_at":"2015-02-24T18:27:43Z","body":"I haven't dived into `go-yaml` sources too much, but it appears to me that when I marshal `time.Time`, it uses `Time.String` to encode the field. Then it uses `Time.UnmarshalText` to decode it. But these methods use different formats and the whole thing fails with something like `parsing time \"2015-02-17T12:15:23+01:00\" as \"2006-01-02 15:04:05.999999999 -0700 MST\": cannot parse \"T12:15:23+01:00\" as \" \"`, so I ended up wrapping `time.Time` like\r\n\r\n```go\r\ntype Time time.Time\r\n\r\nfunc (t Time) String() string {\r\n    raw, err := time.Time(t).MarshalText()\r\n    if err != nil {\r\n        panic(err)\r\n    }   \r\n    return string(raw)\r\n}\r\n```\r\n\r\nNow it works just fine."},"comment":{"url":"https://api.github.com/repos/go-yaml/yaml/issues/comments/75864041","html_url":"https://github.com/go-yaml/yaml/issues/82#issuecomment-75864041","issue_url":"https://api.github.com/repos/go-yaml/yaml/issues/82","id":75864041,"user":{"login":"tchap","id":697127,"avatar_url":"https://avatars.githubusercontent.com/u/697127?v=3","gravatar_id":"","url":"https://api.github.com/users/tchap","html_url":"https://github.com/tchap","followers_url":"https://api.github.com/users/tchap/followers","following_url":"https://api.github.com/users/tchap/following{/other_user}","gists_url":"https://api.github.com/users/tchap/gists{/gist_id}","starred_url":"https://api.github.com/users/tchap/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tchap/subscriptions","organizations_url":"https://api.github.com/users/tchap/orgs","repos_url":"https://api.github.com/users/tchap/repos","events_url":"https://api.github.com/users/tchap/events{/privacy}","received_events_url":"https://api.github.com/users/tchap/received_events","type":"User","site_admin":false},"created_at":"2015-02-24T22:47:37Z","updated_at":"2015-02-24T22:47:37Z","body":"Pulled to use the latest `v2`.\r\n\r\nStill getting `parsing time \"2015-02-24 23:39:59.39193313 +0100 CET\" as \"2006-01-02T15:04:05Z07:00\": cannot parse \" 23:39:59.39193313 +0100 CET\" as \"T\"`. The only thing that I am doing is to encode `time.Time` and then read it again...\r\n\r\nLooks weird, gonna keep researching..."}}