{"action":"created","issue":{"url":"https://api.github.com/repos/bitwalker/timex/issues/385","repository_url":"https://api.github.com/repos/bitwalker/timex","labels_url":"https://api.github.com/repos/bitwalker/timex/issues/385/labels{/name}","comments_url":"https://api.github.com/repos/bitwalker/timex/issues/385/comments","events_url":"https://api.github.com/repos/bitwalker/timex/issues/385/events","html_url":"https://github.com/bitwalker/timex/pull/385","id":268153214,"number":385,"title":"Validate granularity on diff even when values are equal","user":{"login":"fsabe","id":510705,"avatar_url":"https://avatars2.githubusercontent.com/u/510705?v=4","gravatar_id":"","url":"https://api.github.com/users/fsabe","html_url":"https://github.com/fsabe","followers_url":"https://api.github.com/users/fsabe/followers","following_url":"https://api.github.com/users/fsabe/following{/other_user}","gists_url":"https://api.github.com/users/fsabe/gists{/gist_id}","starred_url":"https://api.github.com/users/fsabe/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/fsabe/subscriptions","organizations_url":"https://api.github.com/users/fsabe/orgs","repos_url":"https://api.github.com/users/fsabe/repos","events_url":"https://api.github.com/users/fsabe/events{/privacy}","received_events_url":"https://api.github.com/users/fsabe/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":0,"created_at":"2017-10-24T19:15:46Z","updated_at":"2017-10-24T19:18:30Z","closed_at":null,"author_association":"CONTRIBUTOR","pull_request":{"url":"https://api.github.com/repos/bitwalker/timex/pulls/385","html_url":"https://github.com/bitwalker/timex/pull/385","diff_url":"https://github.com/bitwalker/timex/pull/385.diff","patch_url":"https://github.com/bitwalker/timex/pull/385.patch"},"body":"Issue #384\r\nThis fixes the granularity validity not being checked when applying diff on equal values.\r\n\r\nThis makes the behavior consistent. Currently diff only fails with an invalid value when comparing times:\r\n```elixir\r\niex(1)> Timex.diff(~N[2012-12-12 12:00:00], ~N[2012-12-12 12:00:00], :invalid)\r\n0\r\niex(2)> Timex.diff(~D[2012-12-12], ~D[2012-12-12], :invalid)                  \r\n0\r\niex(3)> Timex.diff(~T[12:00:00], ~T[12:00:00], :invalid)            \r\n{:error, {:invalid_granularity, :invalid}}\r\n```"},"comment":{"url":"https://api.github.com/repos/bitwalker/timex/issues/comments/339101445","html_url":"https://github.com/bitwalker/timex/pull/385#issuecomment-339101445","issue_url":"https://api.github.com/repos/bitwalker/timex/issues/385","id":339101445,"user":{"login":"coveralls","id":2354108,"avatar_url":"https://avatars1.githubusercontent.com/u/2354108?v=4","gravatar_id":"","url":"https://api.github.com/users/coveralls","html_url":"https://github.com/coveralls","followers_url":"https://api.github.com/users/coveralls/followers","following_url":"https://api.github.com/users/coveralls/following{/other_user}","gists_url":"https://api.github.com/users/coveralls/gists{/gist_id}","starred_url":"https://api.github.com/users/coveralls/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/coveralls/subscriptions","organizations_url":"https://api.github.com/users/coveralls/orgs","repos_url":"https://api.github.com/users/coveralls/repos","events_url":"https://api.github.com/users/coveralls/events{/privacy}","received_events_url":"https://api.github.com/users/coveralls/received_events","type":"User","site_admin":false},"created_at":"2017-10-24T19:18:30Z","updated_at":"2017-10-24T19:18:30Z","author_association":"NONE","body":"\n[![Coverage Status](https://coveralls.io/builds/13868926/badge)](https://coveralls.io/builds/13868926)\n\nCoverage increased (+0.001%) to 67.988% when pulling **263a1e7dbb95d029d5b1a81077052c8d283f9081 on fsabe:assertive-diff** into **c86a96af43cb0052249a4899d988aaa4f665982b on bitwalker:master**.\n"}}
{"actor":{"display_login":"coveralls"}}