{"action":"opened","number":247,"pull_request":{"url":"https://api.github.com/repos/BaseAdresseNationale/ban/pulls/247","id":93183136,"html_url":"https://github.com/BaseAdresseNationale/ban/pull/247","diff_url":"https://github.com/BaseAdresseNationale/ban/pull/247.diff","patch_url":"https://github.com/BaseAdresseNationale/ban/pull/247.patch","issue_url":"https://api.github.com/repos/BaseAdresseNationale/ban/issues/247","number":247,"state":"open","locked":false,"title":"Postcode complement","user":{"login":"yohanboniface","id":146023,"avatar_url":"https://avatars.githubusercontent.com/u/146023?v=3","gravatar_id":"","url":"https://api.github.com/users/yohanboniface","html_url":"https://github.com/yohanboniface","followers_url":"https://api.github.com/users/yohanboniface/followers","following_url":"https://api.github.com/users/yohanboniface/following{/other_user}","gists_url":"https://api.github.com/users/yohanboniface/gists{/gist_id}","starred_url":"https://api.github.com/users/yohanboniface/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/yohanboniface/subscriptions","organizations_url":"https://api.github.com/users/yohanboniface/orgs","repos_url":"https://api.github.com/users/yohanboniface/repos","events_url":"https://api.github.com/users/yohanboniface/events{/privacy}","received_events_url":"https://api.github.com/users/yohanboniface/received_events","type":"User","site_admin":false},"body":"While working on this I also discovered that the multi columns unique indexes were not checked by the validor, which had some issues:\r\n\r\n- when one value is \"null\", PostgreSQL does not consider the row for the unicity check, so one can add multiple times A=1,B=null,C=3 even if there is a unique constrainit on A,B,C\r\n- when postgresql would complain because we are trying to add twice the same values, we were not catching it, so => 500\r\n- as much as possible, we prefer to return all the errors in once to the user; so if we only tried to catch the SQL IntegrityError at save time, one may have a document returning some errors, then fix those errors, then send back the document, and get a new error, which is not friendly","created_at":"2016-11-10T16:25:34Z","updated_at":"2016-11-10T16:25:34Z","closed_at":null,"merged_at":null,"merge_commit_sha":null,"assignee":null,"assignees":[],"milestone":null,"commits_url":"https://api.github.com/repos/BaseAdresseNationale/ban/pulls/247/commits","review_comments_url":"https://api.github.com/repos/BaseAdresseNationale/ban/pulls/247/comments","review_comment_url":"https://api.github.com/repos/BaseAdresseNationale/ban/pulls/comments{/number}","comments_url":"https://api.github.com/repos/BaseAdresseNationale/ban/issues/247/comments","statuses_url":"https://api.github.com/repos/BaseAdresseNationale/ban/statuses/bd481ff1b05ada8703ba93e28648b225e71d22d3","head":{"label":"BaseAdresseNationale:postcode-complement","ref":"postcode-complement","sha":"bd481ff1b05ada8703ba93e28648b225e71d22d3","user":{"login":"BaseAdresseNationale","id":19411687,"avatar_url":"https://avatars.githubusercontent.com/u/19411687?v=3","gravatar_id":"","url":"https://api.github.com/users/BaseAdresseNationale","html_url":"https://github.com/BaseAdresseNationale","followers_url":"https://api.github.com/users/BaseAdresseNationale/followers","following_url":"https://api.github.com/users/BaseAdresseNationale/following{/other_user}","gists_url":"https://api.github.com/users/BaseAdresseNationale/gists{/gist_id}","starred_url":"https://api.github.com/users/BaseAdresseNationale/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/BaseAdresseNationale/subscriptions","organizations_url":"https://api.github.com/users/BaseAdresseNationale/orgs","repos_url":"https://api.github.com/users/BaseAdresseNationale/repos","events_url":"https://api.github.com/users/BaseAdresseNationale/events{/privacy}","received_events_url":"https://api.github.com/users/BaseAdresseNationale/received_events","type":"Organization","site_admin":false},"repo":{"id":44619367,"name":"ban","full_name":"BaseAdresseNationale/ban","owner":{"login":"BaseAdresseNationale","id":19411687,"avatar_url":"https://avatars.githubusercontent.com/u/19411687?v=3","gravatar_id":"","url":"https://api.github.com/users/BaseAdresseNationale","html_url":"https://github.com/BaseAdresseNationale","followers_url":"https://api.github.com/users/BaseAdresseNationale/followers","following_url":"https://api.github.com/users/BaseAdresseNationale/following{/other_user}","gists_url":"https://api.github.com/users/BaseAdresseNationale/gists{/gist_id}","starred_url":"https://api.github.com/users/BaseAdresseNationale/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/BaseAdresseNationale/subscriptions","organizations_url":"https://api.github.com/users/BaseAdresseNationale/orgs","repos_url":"https://api.github.com/users/BaseAdresseNationale/repos","events_url":"https://api.github.com/users/BaseAdresseNationale/events{/privacy}","received_events_url":"https://api.github.com/users/BaseAdresseNationale/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/BaseAdresseNationale/ban","description":"Prototype de la future API de gestion de la Base adresses nationale","fork":false,"url":"https://api.github.com/repos/BaseAdresseNationale/ban","forks_url":"https://api.github.com/repos/BaseAdresseNationale/ban/forks","keys_url":"https://api.github.com/repos/BaseAdresseNationale/ban/keys{/key_id}","collaborators_url":"https://api.github.com/repos/BaseAdresseNationale/ban/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/BaseAdresseNationale/ban/teams","hooks_url":"https://api.github.com/repos/BaseAdresseNationale/ban/hooks","issue_events_url":"https://api.github.com/repos/BaseAdresseNationale/ban/issues/events{/number}","events_url":"https://api.github.com/repos/BaseAdresseNationale/ban/events","assignees_url":"https://api.github.com/repos/BaseAdresseNationale/ban/assignees{/user}","branches_url":"https://api.github.com/repos/BaseAdresseNationale/ban/branches{/branch}","tags_url":"https://api.github.com/repos/BaseAdresseNationale/ban/tags","blobs_url":"https://api.github.com/repos/BaseAdresseNationale/ban/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/BaseAdresseNationale/ban/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/BaseAdresseNationale/ban/git/refs{/sha}","trees_url":"https://api.github.com/repos/BaseAdresseNationale/ban/git/trees{/sha}","statuses_url":"https://api.github.com/repos/BaseAdresseNationale/ban/statuses/{sha}","languages_url":"https://api.github.com/repos/BaseAdresseNationale/ban/languages","stargazers_url":"https://api.github.com/repos/BaseAdresseNationale/ban/stargazers","contributors_url":"https://api.github.com/repos/BaseAdresseNationale/ban/contributors","subscribers_url":"https://api.github.com/repos/BaseAdresseNationale/ban/subscribers","subscription_url":"https://api.github.com/repos/BaseAdresseNationale/ban/subscription","commits_url":"https://api.github.com/repos/BaseAdresseNationale/ban/commits{/sha}","git_commits_url":"https://api.github.com/repos/BaseAdresseNationale/ban/git/commits{/sha}","comments_url":"https://api.github.com/repos/BaseAdresseNationale/ban/comments{/number}","issue_comment_url":"https://api.github.com/repos/BaseAdresseNationale/ban/issues/comments{/number}","contents_url":"https://api.github.com/repos/BaseAdresseNationale/ban/contents/{+path}","compare_url":"https://api.github.com/repos/BaseAdresseNationale/ban/compare/{base}...{head}","merges_url":"https://api.github.com/repos/BaseAdresseNationale/ban/merges","archive_url":"https://api.github.com/repos/BaseAdresseNationale/ban/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/BaseAdresseNationale/ban/downloads","issues_url":"https://api.github.com/repos/BaseAdresseNationale/ban/issues{/number}","pulls_url":"https://api.github.com/repos/BaseAdresseNationale/ban/pulls{/number}","milestones_url":"https://api.github.com/repos/BaseAdresseNationale/ban/milestones{/number}","notifications_url":"https://api.github.com/repos/BaseAdresseNationale/ban/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/BaseAdresseNationale/ban/labels{/name}","releases_url":"https://api.github.com/repos/BaseAdresseNationale/ban/releases{/id}","deployments_url":"https://api.github.com/repos/BaseAdresseNationale/ban/deployments","created_at":"2015-10-20T16:24:34Z","updated_at":"2016-10-27T07:13:35Z","pushed_at":"2016-11-10T16:13:31Z","git_url":"git://github.com/BaseAdresseNationale/ban.git","ssh_url":"git@github.com:BaseAdresseNationale/ban.git","clone_url":"https://github.com/BaseAdresseNationale/ban.git","svn_url":"https://github.com/BaseAdresseNationale/ban","homepage":"","size":753,"stargazers_count":9,"watchers_count":9,"language":"Python","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":10,"mirror_url":null,"open_issues_count":93,"forks":10,"open_issues":93,"watchers":9,"default_branch":"master"}},"base":{"label":"BaseAdresseNationale:master","ref":"master","sha":"537c6be9842306f9b653ffed739f785216f39d2f","user":{"login":"BaseAdresseNationale","id":19411687,"avatar_url":"https://avatars.githubusercontent.com/u/19411687?v=3","gravatar_id":"","url":"https://api.github.com/users/BaseAdresseNationale","html_url":"https://github.com/BaseAdresseNationale","followers_url":"https://api.github.com/users/BaseAdresseNationale/followers","following_url":"https://api.github.com/users/BaseAdresseNationale/following{/other_user}","gists_url":"https://api.github.com/users/BaseAdresseNationale/gists{/gist_id}","starred_url":"https://api.github.com/users/BaseAdresseNationale/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/BaseAdresseNationale/subscriptions","organizations_url":"https://api.github.com/users/BaseAdresseNationale/orgs","repos_url":"https://api.github.com/users/BaseAdresseNationale/repos","events_url":"https://api.github.com/users/BaseAdresseNationale/events{/privacy}","received_events_url":"https://api.github.com/users/BaseAdresseNationale/received_events","type":"Organization","site_admin":false},"repo":{"id":44619367,"name":"ban","full_name":"BaseAdresseNationale/ban","owner":{"login":"BaseAdresseNationale","id":19411687,"avatar_url":"https://avatars.githubusercontent.com/u/19411687?v=3","gravatar_id":"","url":"https://api.github.com/users/BaseAdresseNationale","html_url":"https://github.com/BaseAdresseNationale","followers_url":"https://api.github.com/users/BaseAdresseNationale/followers","following_url":"https://api.github.com/users/BaseAdresseNationale/following{/other_user}","gists_url":"https://api.github.com/users/BaseAdresseNationale/gists{/gist_id}","starred_url":"https://api.github.com/users/BaseAdresseNationale/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/BaseAdresseNationale/subscriptions","organizations_url":"https://api.github.com/users/BaseAdresseNationale/orgs","repos_url":"https://api.github.com/users/BaseAdresseNationale/repos","events_url":"https://api.github.com/users/BaseAdresseNationale/events{/privacy}","received_events_url":"https://api.github.com/users/BaseAdresseNationale/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/BaseAdresseNationale/ban","description":"Prototype de la future API de gestion de la Base adresses nationale","fork":false,"url":"https://api.github.com/repos/BaseAdresseNationale/ban","forks_url":"https://api.github.com/repos/BaseAdresseNationale/ban/forks","keys_url":"https://api.github.com/repos/BaseAdresseNationale/ban/keys{/key_id}","collaborators_url":"https://api.github.com/repos/BaseAdresseNationale/ban/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/BaseAdresseNationale/ban/teams","hooks_url":"https://api.github.com/repos/BaseAdresseNationale/ban/hooks","issue_events_url":"https://api.github.com/repos/BaseAdresseNationale/ban/issues/events{/number}","events_url":"https://api.github.com/repos/BaseAdresseNationale/ban/events","assignees_url":"https://api.github.com/repos/BaseAdresseNationale/ban/assignees{/user}","branches_url":"https://api.github.com/repos/BaseAdresseNationale/ban/branches{/branch}","tags_url":"https://api.github.com/repos/BaseAdresseNationale/ban/tags","blobs_url":"https://api.github.com/repos/BaseAdresseNationale/ban/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/BaseAdresseNationale/ban/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/BaseAdresseNationale/ban/git/refs{/sha}","trees_url":"https://api.github.com/repos/BaseAdresseNationale/ban/git/trees{/sha}","statuses_url":"https://api.github.com/repos/BaseAdresseNationale/ban/statuses/{sha}","languages_url":"https://api.github.com/repos/BaseAdresseNationale/ban/languages","stargazers_url":"https://api.github.com/repos/BaseAdresseNationale/ban/stargazers","contributors_url":"https://api.github.com/repos/BaseAdresseNationale/ban/contributors","subscribers_url":"https://api.github.com/repos/BaseAdresseNationale/ban/subscribers","subscription_url":"https://api.github.com/repos/BaseAdresseNationale/ban/subscription","commits_url":"https://api.github.com/repos/BaseAdresseNationale/ban/commits{/sha}","git_commits_url":"https://api.github.com/repos/BaseAdresseNationale/ban/git/commits{/sha}","comments_url":"https://api.github.com/repos/BaseAdresseNationale/ban/comments{/number}","issue_comment_url":"https://api.github.com/repos/BaseAdresseNationale/ban/issues/comments{/number}","contents_url":"https://api.github.com/repos/BaseAdresseNationale/ban/contents/{+path}","compare_url":"https://api.github.com/repos/BaseAdresseNationale/ban/compare/{base}...{head}","merges_url":"https://api.github.com/repos/BaseAdresseNationale/ban/merges","archive_url":"https://api.github.com/repos/BaseAdresseNationale/ban/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/BaseAdresseNationale/ban/downloads","issues_url":"https://api.github.com/repos/BaseAdresseNationale/ban/issues{/number}","pulls_url":"https://api.github.com/repos/BaseAdresseNationale/ban/pulls{/number}","milestones_url":"https://api.github.com/repos/BaseAdresseNationale/ban/milestones{/number}","notifications_url":"https://api.github.com/repos/BaseAdresseNationale/ban/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/BaseAdresseNationale/ban/labels{/name}","releases_url":"https://api.github.com/repos/BaseAdresseNationale/ban/releases{/id}","deployments_url":"https://api.github.com/repos/BaseAdresseNationale/ban/deployments","created_at":"2015-10-20T16:24:34Z","updated_at":"2016-10-27T07:13:35Z","pushed_at":"2016-11-10T16:13:31Z","git_url":"git://github.com/BaseAdresseNationale/ban.git","ssh_url":"git@github.com:BaseAdresseNationale/ban.git","clone_url":"https://github.com/BaseAdresseNationale/ban.git","svn_url":"https://github.com/BaseAdresseNationale/ban","homepage":"","size":753,"stargazers_count":9,"watchers_count":9,"language":"Python","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":10,"mirror_url":null,"open_issues_count":93,"forks":10,"open_issues":93,"watchers":9,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/BaseAdresseNationale/ban/pulls/247"},"html":{"href":"https://github.com/BaseAdresseNationale/ban/pull/247"},"issue":{"href":"https://api.github.com/repos/BaseAdresseNationale/ban/issues/247"},"comments":{"href":"https://api.github.com/repos/BaseAdresseNationale/ban/issues/247/comments"},"review_comments":{"href":"https://api.github.com/repos/BaseAdresseNationale/ban/pulls/247/comments"},"review_comment":{"href":"https://api.github.com/repos/BaseAdresseNationale/ban/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/BaseAdresseNationale/ban/pulls/247/commits"},"statuses":{"href":"https://api.github.com/repos/BaseAdresseNationale/ban/statuses/bd481ff1b05ada8703ba93e28648b225e71d22d3"}},"merged":false,"mergeable":null,"mergeable_state":"unknown","merged_by":null,"comments":0,"review_comments":0,"commits":3,"additions":117,"deletions":19,"changed_files":5}}
{"actor":{"display_login":"yohanboniface"}}