{"action":"created","comment":{"url":"https://api.github.com/repos/DockYard/valid_field/pulls/comments/75914838","id":75914838,"diff_hunk":"@@ -23,6 +23,11 @@ defmodule ValidFieldTest do\n       ValidField.with_changeset(%Model{})\n       |> ValidField.assert_invalid_field(:title, [\"\", nil, \"Something else\"])\n     end\n+\n+    assert_raise ValidField.ValidationError, \"Expected the following values to be invalid for \\\"date_of_birth\\\": #Ecto.Date<2016-08-23>\", fn ->","path":"test/valid_field_test.exs","position":5,"original_position":5,"commit_id":"c9fc713e9bf81b999b3f32fa5481e414076ae3dd","original_commit_id":"c9fc713e9bf81b999b3f32fa5481e414076ae3dd","user":{"login":"bcardarella","id":18524,"avatar_url":"https://avatars.githubusercontent.com/u/18524?v=3","gravatar_id":"","url":"https://api.github.com/users/bcardarella","html_url":"https://github.com/bcardarella","followers_url":"https://api.github.com/users/bcardarella/followers","following_url":"https://api.github.com/users/bcardarella/following{/other_user}","gists_url":"https://api.github.com/users/bcardarella/gists{/gist_id}","starred_url":"https://api.github.com/users/bcardarella/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bcardarella/subscriptions","organizations_url":"https://api.github.com/users/bcardarella/orgs","repos_url":"https://api.github.com/users/bcardarella/repos","events_url":"https://api.github.com/users/bcardarella/events{/privacy}","received_events_url":"https://api.github.com/users/bcardarella/received_events","type":"User","site_admin":false},"body":"Ah, nevermind. I overlooked that this was part of the assertion. You can keep as-is","created_at":"2016-08-23T17:38:12Z","updated_at":"2016-08-23T17:38:12Z","html_url":"https://github.com/DockYard/valid_field/pull/21#discussion_r75914838","pull_request_url":"https://api.github.com/repos/DockYard/valid_field/pulls/21","_links":{"self":{"href":"https://api.github.com/repos/DockYard/valid_field/pulls/comments/75914838"},"html":{"href":"https://github.com/DockYard/valid_field/pull/21#discussion_r75914838"},"pull_request":{"href":"https://api.github.com/repos/DockYard/valid_field/pulls/21"}}},"pull_request":{"url":"https://api.github.com/repos/DockYard/valid_field/pulls/21","id":82392443,"html_url":"https://github.com/DockYard/valid_field/pull/21","diff_url":"https://github.com/DockYard/valid_field/pull/21.diff","patch_url":"https://github.com/DockYard/valid_field/pull/21.patch","issue_url":"https://api.github.com/repos/DockYard/valid_field/issues/21","number":21,"state":"open","locked":false,"title":"Fix error when stringifying structs","user":{"login":"BlakeWilliams","id":342554,"avatar_url":"https://avatars.githubusercontent.com/u/342554?v=3","gravatar_id":"","url":"https://api.github.com/users/BlakeWilliams","html_url":"https://github.com/BlakeWilliams","followers_url":"https://api.github.com/users/BlakeWilliams/followers","following_url":"https://api.github.com/users/BlakeWilliams/following{/other_user}","gists_url":"https://api.github.com/users/BlakeWilliams/gists{/gist_id}","starred_url":"https://api.github.com/users/BlakeWilliams/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/BlakeWilliams/subscriptions","organizations_url":"https://api.github.com/users/BlakeWilliams/orgs","repos_url":"https://api.github.com/users/BlakeWilliams/repos","events_url":"https://api.github.com/users/BlakeWilliams/events{/privacy}","received_events_url":"https://api.github.com/users/BlakeWilliams/received_events","type":"User","site_admin":false},"body":"When trying to stringify a struct an error is raised because structs\r\ndon't implement enumerable by default. This happens because using\r\n`Kernel.is_map/1` matches both structs and maps.\r\n\r\nThe fix is to pattern match against `%{__struct__: _struct}` before\r\nusing a guard with `is_map`.\r\n\r\nLet me know if this solution works out or if there's a better alternative, thanks!","created_at":"2016-08-23T15:56:27Z","updated_at":"2016-08-23T17:38:12Z","closed_at":null,"merged_at":null,"merge_commit_sha":"a78b8100bb3ab7726e53361566dedc65e50f7038","assignee":null,"assignees":[],"milestone":null,"commits_url":"https://api.github.com/repos/DockYard/valid_field/pulls/21/commits","review_comments_url":"https://api.github.com/repos/DockYard/valid_field/pulls/21/comments","review_comment_url":"https://api.github.com/repos/DockYard/valid_field/pulls/comments{/number}","comments_url":"https://api.github.com/repos/DockYard/valid_field/issues/21/comments","statuses_url":"https://api.github.com/repos/DockYard/valid_field/statuses/c9fc713e9bf81b999b3f32fa5481e414076ae3dd","head":{"label":"BlakeWilliams:bmw-struct-stringify","ref":"bmw-struct-stringify","sha":"c9fc713e9bf81b999b3f32fa5481e414076ae3dd","user":{"login":"BlakeWilliams","id":342554,"avatar_url":"https://avatars.githubusercontent.com/u/342554?v=3","gravatar_id":"","url":"https://api.github.com/users/BlakeWilliams","html_url":"https://github.com/BlakeWilliams","followers_url":"https://api.github.com/users/BlakeWilliams/followers","following_url":"https://api.github.com/users/BlakeWilliams/following{/other_user}","gists_url":"https://api.github.com/users/BlakeWilliams/gists{/gist_id}","starred_url":"https://api.github.com/users/BlakeWilliams/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/BlakeWilliams/subscriptions","organizations_url":"https://api.github.com/users/BlakeWilliams/orgs","repos_url":"https://api.github.com/users/BlakeWilliams/repos","events_url":"https://api.github.com/users/BlakeWilliams/events{/privacy}","received_events_url":"https://api.github.com/users/BlakeWilliams/received_events","type":"User","site_admin":false},"repo":{"id":66380777,"name":"valid_field","full_name":"BlakeWilliams/valid_field","owner":{"login":"BlakeWilliams","id":342554,"avatar_url":"https://avatars.githubusercontent.com/u/342554?v=3","gravatar_id":"","url":"https://api.github.com/users/BlakeWilliams","html_url":"https://github.com/BlakeWilliams","followers_url":"https://api.github.com/users/BlakeWilliams/followers","following_url":"https://api.github.com/users/BlakeWilliams/following{/other_user}","gists_url":"https://api.github.com/users/BlakeWilliams/gists{/gist_id}","starred_url":"https://api.github.com/users/BlakeWilliams/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/BlakeWilliams/subscriptions","organizations_url":"https://api.github.com/users/BlakeWilliams/orgs","repos_url":"https://api.github.com/users/BlakeWilliams/repos","events_url":"https://api.github.com/users/BlakeWilliams/events{/privacy}","received_events_url":"https://api.github.com/users/BlakeWilliams/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/BlakeWilliams/valid_field","description":null,"fork":true,"url":"https://api.github.com/repos/BlakeWilliams/valid_field","forks_url":"https://api.github.com/repos/BlakeWilliams/valid_field/forks","keys_url":"https://api.github.com/repos/BlakeWilliams/valid_field/keys{/key_id}","collaborators_url":"https://api.github.com/repos/BlakeWilliams/valid_field/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/BlakeWilliams/valid_field/teams","hooks_url":"https://api.github.com/repos/BlakeWilliams/valid_field/hooks","issue_events_url":"https://api.github.com/repos/BlakeWilliams/valid_field/issues/events{/number}","events_url":"https://api.github.com/repos/BlakeWilliams/valid_field/events","assignees_url":"https://api.github.com/repos/BlakeWilliams/valid_field/assignees{/user}","branches_url":"https://api.github.com/repos/BlakeWilliams/valid_field/branches{/branch}","tags_url":"https://api.github.com/repos/BlakeWilliams/valid_field/tags","blobs_url":"https://api.github.com/repos/BlakeWilliams/valid_field/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/BlakeWilliams/valid_field/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/BlakeWilliams/valid_field/git/refs{/sha}","trees_url":"https://api.github.com/repos/BlakeWilliams/valid_field/git/trees{/sha}","statuses_url":"https://api.github.com/repos/BlakeWilliams/valid_field/statuses/{sha}","languages_url":"https://api.github.com/repos/BlakeWilliams/valid_field/languages","stargazers_url":"https://api.github.com/repos/BlakeWilliams/valid_field/stargazers","contributors_url":"https://api.github.com/repos/BlakeWilliams/valid_field/contributors","subscribers_url":"https://api.github.com/repos/BlakeWilliams/valid_field/subscribers","subscription_url":"https://api.github.com/repos/BlakeWilliams/valid_field/subscription","commits_url":"https://api.github.com/repos/BlakeWilliams/valid_field/commits{/sha}","git_commits_url":"https://api.github.com/repos/BlakeWilliams/valid_field/git/commits{/sha}","comments_url":"https://api.github.com/repos/BlakeWilliams/valid_field/comments{/number}","issue_comment_url":"https://api.github.com/repos/BlakeWilliams/valid_field/issues/comments{/number}","contents_url":"https://api.github.com/repos/BlakeWilliams/valid_field/contents/{+path}","compare_url":"https://api.github.com/repos/BlakeWilliams/valid_field/compare/{base}...{head}","merges_url":"https://api.github.com/repos/BlakeWilliams/valid_field/merges","archive_url":"https://api.github.com/repos/BlakeWilliams/valid_field/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/BlakeWilliams/valid_field/downloads","issues_url":"https://api.github.com/repos/BlakeWilliams/valid_field/issues{/number}","pulls_url":"https://api.github.com/repos/BlakeWilliams/valid_field/pulls{/number}","milestones_url":"https://api.github.com/repos/BlakeWilliams/valid_field/milestones{/number}","notifications_url":"https://api.github.com/repos/BlakeWilliams/valid_field/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/BlakeWilliams/valid_field/labels{/name}","releases_url":"https://api.github.com/repos/BlakeWilliams/valid_field/releases{/id}","deployments_url":"https://api.github.com/repos/BlakeWilliams/valid_field/deployments","created_at":"2016-08-23T15:44:38Z","updated_at":"2016-08-23T15:44:39Z","pushed_at":"2016-08-23T15:57:08Z","git_url":"git://github.com/BlakeWilliams/valid_field.git","ssh_url":"git@github.com:BlakeWilliams/valid_field.git","clone_url":"https://github.com/BlakeWilliams/valid_field.git","svn_url":"https://github.com/BlakeWilliams/valid_field","homepage":"https://hex.pm/packages/valid_field","size":34,"stargazers_count":0,"watchers_count":0,"language":"Elixir","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"DockYard:master","ref":"master","sha":"83d9da019587a3a56342b8a6107fb6450fe7c372","user":{"login":"DockYard","id":873981,"avatar_url":"https://avatars.githubusercontent.com/u/873981?v=3","gravatar_id":"","url":"https://api.github.com/users/DockYard","html_url":"https://github.com/DockYard","followers_url":"https://api.github.com/users/DockYard/followers","following_url":"https://api.github.com/users/DockYard/following{/other_user}","gists_url":"https://api.github.com/users/DockYard/gists{/gist_id}","starred_url":"https://api.github.com/users/DockYard/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/DockYard/subscriptions","organizations_url":"https://api.github.com/users/DockYard/orgs","repos_url":"https://api.github.com/users/DockYard/repos","events_url":"https://api.github.com/users/DockYard/events{/privacy}","received_events_url":"https://api.github.com/users/DockYard/received_events","type":"Organization","site_admin":false},"repo":{"id":44936346,"name":"valid_field","full_name":"DockYard/valid_field","owner":{"login":"DockYard","id":873981,"avatar_url":"https://avatars.githubusercontent.com/u/873981?v=3","gravatar_id":"","url":"https://api.github.com/users/DockYard","html_url":"https://github.com/DockYard","followers_url":"https://api.github.com/users/DockYard/followers","following_url":"https://api.github.com/users/DockYard/following{/other_user}","gists_url":"https://api.github.com/users/DockYard/gists{/gist_id}","starred_url":"https://api.github.com/users/DockYard/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/DockYard/subscriptions","organizations_url":"https://api.github.com/users/DockYard/orgs","repos_url":"https://api.github.com/users/DockYard/repos","events_url":"https://api.github.com/users/DockYard/events{/privacy}","received_events_url":"https://api.github.com/users/DockYard/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/DockYard/valid_field","description":"","fork":false,"url":"https://api.github.com/repos/DockYard/valid_field","forks_url":"https://api.github.com/repos/DockYard/valid_field/forks","keys_url":"https://api.github.com/repos/DockYard/valid_field/keys{/key_id}","collaborators_url":"https://api.github.com/repos/DockYard/valid_field/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/DockYard/valid_field/teams","hooks_url":"https://api.github.com/repos/DockYard/valid_field/hooks","issue_events_url":"https://api.github.com/repos/DockYard/valid_field/issues/events{/number}","events_url":"https://api.github.com/repos/DockYard/valid_field/events","assignees_url":"https://api.github.com/repos/DockYard/valid_field/assignees{/user}","branches_url":"https://api.github.com/repos/DockYard/valid_field/branches{/branch}","tags_url":"https://api.github.com/repos/DockYard/valid_field/tags","blobs_url":"https://api.github.com/repos/DockYard/valid_field/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/DockYard/valid_field/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/DockYard/valid_field/git/refs{/sha}","trees_url":"https://api.github.com/repos/DockYard/valid_field/git/trees{/sha}","statuses_url":"https://api.github.com/repos/DockYard/valid_field/statuses/{sha}","languages_url":"https://api.github.com/repos/DockYard/valid_field/languages","stargazers_url":"https://api.github.com/repos/DockYard/valid_field/stargazers","contributors_url":"https://api.github.com/repos/DockYard/valid_field/contributors","subscribers_url":"https://api.github.com/repos/DockYard/valid_field/subscribers","subscription_url":"https://api.github.com/repos/DockYard/valid_field/subscription","commits_url":"https://api.github.com/repos/DockYard/valid_field/commits{/sha}","git_commits_url":"https://api.github.com/repos/DockYard/valid_field/git/commits{/sha}","comments_url":"https://api.github.com/repos/DockYard/valid_field/comments{/number}","issue_comment_url":"https://api.github.com/repos/DockYard/valid_field/issues/comments{/number}","contents_url":"https://api.github.com/repos/DockYard/valid_field/contents/{+path}","compare_url":"https://api.github.com/repos/DockYard/valid_field/compare/{base}...{head}","merges_url":"https://api.github.com/repos/DockYard/valid_field/merges","archive_url":"https://api.github.com/repos/DockYard/valid_field/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/DockYard/valid_field/downloads","issues_url":"https://api.github.com/repos/DockYard/valid_field/issues{/number}","pulls_url":"https://api.github.com/repos/DockYard/valid_field/pulls{/number}","milestones_url":"https://api.github.com/repos/DockYard/valid_field/milestones{/number}","notifications_url":"https://api.github.com/repos/DockYard/valid_field/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/DockYard/valid_field/labels{/name}","releases_url":"https://api.github.com/repos/DockYard/valid_field/releases{/id}","deployments_url":"https://api.github.com/repos/DockYard/valid_field/deployments","created_at":"2015-10-26T00:18:01Z","updated_at":"2016-07-25T08:07:42Z","pushed_at":"2016-08-23T15:57:08Z","git_url":"git://github.com/DockYard/valid_field.git","ssh_url":"git@github.com:DockYard/valid_field.git","clone_url":"https://github.com/DockYard/valid_field.git","svn_url":"https://github.com/DockYard/valid_field","homepage":"https://hex.pm/packages/valid_field","size":40,"stargazers_count":31,"watchers_count":31,"language":"Elixir","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":6,"mirror_url":null,"open_issues_count":5,"forks":6,"open_issues":5,"watchers":31,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/DockYard/valid_field/pulls/21"},"html":{"href":"https://github.com/DockYard/valid_field/pull/21"},"issue":{"href":"https://api.github.com/repos/DockYard/valid_field/issues/21"},"comments":{"href":"https://api.github.com/repos/DockYard/valid_field/issues/21/comments"},"review_comments":{"href":"https://api.github.com/repos/DockYard/valid_field/pulls/21/comments"},"review_comment":{"href":"https://api.github.com/repos/DockYard/valid_field/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/DockYard/valid_field/pulls/21/commits"},"statuses":{"href":"https://api.github.com/repos/DockYard/valid_field/statuses/c9fc713e9bf81b999b3f32fa5481e414076ae3dd"}}}}
{"actor":{"display_login":"bcardarella"}}