{"action":"closed","number":140,"pull_request":{"url":"https://api.github.com/repos/ipython/traitlets/pulls/140","id":52216982,"html_url":"https://github.com/ipython/traitlets/pull/140","diff_url":"https://github.com/ipython/traitlets/pull/140.diff","patch_url":"https://github.com/ipython/traitlets/pull/140.patch","issue_url":"https://api.github.com/repos/ipython/traitlets/issues/140","number":140,"state":"closed","locked":false,"title":"engage cross-validaiton lock for trait types of a union","user":{"login":"rmorshea","id":4041990,"avatar_url":"https://avatars.githubusercontent.com/u/4041990?v=3","gravatar_id":"","url":"https://api.github.com/users/rmorshea","html_url":"https://github.com/rmorshea","followers_url":"https://api.github.com/users/rmorshea/followers","following_url":"https://api.github.com/users/rmorshea/following{/other_user}","gists_url":"https://api.github.com/users/rmorshea/gists{/gist_id}","starred_url":"https://api.github.com/users/rmorshea/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/rmorshea/subscriptions","organizations_url":"https://api.github.com/users/rmorshea/orgs","repos_url":"https://api.github.com/users/rmorshea/repos","events_url":"https://api.github.com/users/rmorshea/events{/privacy}","received_events_url":"https://api.github.com/users/rmorshea/received_events","type":"User","site_admin":false},"body":"When a `Union` validates a value, it calls `_validate` on each of the traits it depends on. However, this means that cross-validation is performed multiple times - once for each `TraitType` the `Union` is wrapping, and then again for the `Union` itself. It doesn't make sense for this to be the case since the `Union` is passed to the cross-validator and would allow the above behavior to be replicated using its `trait_types` attribute without calling the method multiple times.","created_at":"2015-12-01T05:13:16Z","updated_at":"2015-12-01T05:25:59Z","closed_at":"2015-12-01T05:25:59Z","merged_at":null,"merge_commit_sha":"77fef4dacbe8b2359b9c2ffd81b0b69f81668977","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/ipython/traitlets/pulls/140/commits","review_comments_url":"https://api.github.com/repos/ipython/traitlets/pulls/140/comments","review_comment_url":"https://api.github.com/repos/ipython/traitlets/pulls/comments{/number}","comments_url":"https://api.github.com/repos/ipython/traitlets/issues/140/comments","statuses_url":"https://api.github.com/repos/ipython/traitlets/statuses/a40c0bd1feba2eebfd8088f11eead83a0e85db29","head":{"label":"rmorshea:union_cross_validation","ref":"union_cross_validation","sha":"a40c0bd1feba2eebfd8088f11eead83a0e85db29","user":{"login":"rmorshea","id":4041990,"avatar_url":"https://avatars.githubusercontent.com/u/4041990?v=3","gravatar_id":"","url":"https://api.github.com/users/rmorshea","html_url":"https://github.com/rmorshea","followers_url":"https://api.github.com/users/rmorshea/followers","following_url":"https://api.github.com/users/rmorshea/following{/other_user}","gists_url":"https://api.github.com/users/rmorshea/gists{/gist_id}","starred_url":"https://api.github.com/users/rmorshea/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/rmorshea/subscriptions","organizations_url":"https://api.github.com/users/rmorshea/orgs","repos_url":"https://api.github.com/users/rmorshea/repos","events_url":"https://api.github.com/users/rmorshea/events{/privacy}","received_events_url":"https://api.github.com/users/rmorshea/received_events","type":"User","site_admin":false},"repo":{"id":37481051,"name":"traitlets","full_name":"rmorshea/traitlets","owner":{"login":"rmorshea","id":4041990,"avatar_url":"https://avatars.githubusercontent.com/u/4041990?v=3","gravatar_id":"","url":"https://api.github.com/users/rmorshea","html_url":"https://github.com/rmorshea","followers_url":"https://api.github.com/users/rmorshea/followers","following_url":"https://api.github.com/users/rmorshea/following{/other_user}","gists_url":"https://api.github.com/users/rmorshea/gists{/gist_id}","starred_url":"https://api.github.com/users/rmorshea/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/rmorshea/subscriptions","organizations_url":"https://api.github.com/users/rmorshea/orgs","repos_url":"https://api.github.com/users/rmorshea/repos","events_url":"https://api.github.com/users/rmorshea/events{/privacy}","received_events_url":"https://api.github.com/users/rmorshea/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/rmorshea/traitlets","description":"A lightweight Traits like module","fork":true,"url":"https://api.github.com/repos/rmorshea/traitlets","forks_url":"https://api.github.com/repos/rmorshea/traitlets/forks","keys_url":"https://api.github.com/repos/rmorshea/traitlets/keys{/key_id}","collaborators_url":"https://api.github.com/repos/rmorshea/traitlets/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/rmorshea/traitlets/teams","hooks_url":"https://api.github.com/repos/rmorshea/traitlets/hooks","issue_events_url":"https://api.github.com/repos/rmorshea/traitlets/issues/events{/number}","events_url":"https://api.github.com/repos/rmorshea/traitlets/events","assignees_url":"https://api.github.com/repos/rmorshea/traitlets/assignees{/user}","branches_url":"https://api.github.com/repos/rmorshea/traitlets/branches{/branch}","tags_url":"https://api.github.com/repos/rmorshea/traitlets/tags","blobs_url":"https://api.github.com/repos/rmorshea/traitlets/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/rmorshea/traitlets/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/rmorshea/traitlets/git/refs{/sha}","trees_url":"https://api.github.com/repos/rmorshea/traitlets/git/trees{/sha}","statuses_url":"https://api.github.com/repos/rmorshea/traitlets/statuses/{sha}","languages_url":"https://api.github.com/repos/rmorshea/traitlets/languages","stargazers_url":"https://api.github.com/repos/rmorshea/traitlets/stargazers","contributors_url":"https://api.github.com/repos/rmorshea/traitlets/contributors","subscribers_url":"https://api.github.com/repos/rmorshea/traitlets/subscribers","subscription_url":"https://api.github.com/repos/rmorshea/traitlets/subscription","commits_url":"https://api.github.com/repos/rmorshea/traitlets/commits{/sha}","git_commits_url":"https://api.github.com/repos/rmorshea/traitlets/git/commits{/sha}","comments_url":"https://api.github.com/repos/rmorshea/traitlets/comments{/number}","issue_comment_url":"https://api.github.com/repos/rmorshea/traitlets/issues/comments{/number}","contents_url":"https://api.github.com/repos/rmorshea/traitlets/contents/{+path}","compare_url":"https://api.github.com/repos/rmorshea/traitlets/compare/{base}...{head}","merges_url":"https://api.github.com/repos/rmorshea/traitlets/merges","archive_url":"https://api.github.com/repos/rmorshea/traitlets/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/rmorshea/traitlets/downloads","issues_url":"https://api.github.com/repos/rmorshea/traitlets/issues{/number}","pulls_url":"https://api.github.com/repos/rmorshea/traitlets/pulls{/number}","milestones_url":"https://api.github.com/repos/rmorshea/traitlets/milestones{/number}","notifications_url":"https://api.github.com/repos/rmorshea/traitlets/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/rmorshea/traitlets/labels{/name}","releases_url":"https://api.github.com/repos/rmorshea/traitlets/releases{/id}","created_at":"2015-06-15T17:48:57Z","updated_at":"2015-06-15T17:48:58Z","pushed_at":"2015-12-01T05:25:59Z","git_url":"git://github.com/rmorshea/traitlets.git","ssh_url":"git@github.com:rmorshea/traitlets.git","clone_url":"https://github.com/rmorshea/traitlets.git","svn_url":"https://github.com/rmorshea/traitlets","homepage":null,"size":899,"stargazers_count":0,"watchers_count":0,"language":"Python","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":"ipython:master","ref":"master","sha":"0a8201f645e5cc303211af212155040c0bfe53ff","user":{"login":"ipython","id":230453,"avatar_url":"https://avatars.githubusercontent.com/u/230453?v=3","gravatar_id":"","url":"https://api.github.com/users/ipython","html_url":"https://github.com/ipython","followers_url":"https://api.github.com/users/ipython/followers","following_url":"https://api.github.com/users/ipython/following{/other_user}","gists_url":"https://api.github.com/users/ipython/gists{/gist_id}","starred_url":"https://api.github.com/users/ipython/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ipython/subscriptions","organizations_url":"https://api.github.com/users/ipython/orgs","repos_url":"https://api.github.com/users/ipython/repos","events_url":"https://api.github.com/users/ipython/events{/privacy}","received_events_url":"https://api.github.com/users/ipython/received_events","type":"Organization","site_admin":false},"repo":{"id":14993021,"name":"traitlets","full_name":"ipython/traitlets","owner":{"login":"ipython","id":230453,"avatar_url":"https://avatars.githubusercontent.com/u/230453?v=3","gravatar_id":"","url":"https://api.github.com/users/ipython","html_url":"https://github.com/ipython","followers_url":"https://api.github.com/users/ipython/followers","following_url":"https://api.github.com/users/ipython/following{/other_user}","gists_url":"https://api.github.com/users/ipython/gists{/gist_id}","starred_url":"https://api.github.com/users/ipython/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ipython/subscriptions","organizations_url":"https://api.github.com/users/ipython/orgs","repos_url":"https://api.github.com/users/ipython/repos","events_url":"https://api.github.com/users/ipython/events{/privacy}","received_events_url":"https://api.github.com/users/ipython/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/ipython/traitlets","description":"A lightweight Traits like module","fork":false,"url":"https://api.github.com/repos/ipython/traitlets","forks_url":"https://api.github.com/repos/ipython/traitlets/forks","keys_url":"https://api.github.com/repos/ipython/traitlets/keys{/key_id}","collaborators_url":"https://api.github.com/repos/ipython/traitlets/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/ipython/traitlets/teams","hooks_url":"https://api.github.com/repos/ipython/traitlets/hooks","issue_events_url":"https://api.github.com/repos/ipython/traitlets/issues/events{/number}","events_url":"https://api.github.com/repos/ipython/traitlets/events","assignees_url":"https://api.github.com/repos/ipython/traitlets/assignees{/user}","branches_url":"https://api.github.com/repos/ipython/traitlets/branches{/branch}","tags_url":"https://api.github.com/repos/ipython/traitlets/tags","blobs_url":"https://api.github.com/repos/ipython/traitlets/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/ipython/traitlets/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/ipython/traitlets/git/refs{/sha}","trees_url":"https://api.github.com/repos/ipython/traitlets/git/trees{/sha}","statuses_url":"https://api.github.com/repos/ipython/traitlets/statuses/{sha}","languages_url":"https://api.github.com/repos/ipython/traitlets/languages","stargazers_url":"https://api.github.com/repos/ipython/traitlets/stargazers","contributors_url":"https://api.github.com/repos/ipython/traitlets/contributors","subscribers_url":"https://api.github.com/repos/ipython/traitlets/subscribers","subscription_url":"https://api.github.com/repos/ipython/traitlets/subscription","commits_url":"https://api.github.com/repos/ipython/traitlets/commits{/sha}","git_commits_url":"https://api.github.com/repos/ipython/traitlets/git/commits{/sha}","comments_url":"https://api.github.com/repos/ipython/traitlets/comments{/number}","issue_comment_url":"https://api.github.com/repos/ipython/traitlets/issues/comments{/number}","contents_url":"https://api.github.com/repos/ipython/traitlets/contents/{+path}","compare_url":"https://api.github.com/repos/ipython/traitlets/compare/{base}...{head}","merges_url":"https://api.github.com/repos/ipython/traitlets/merges","archive_url":"https://api.github.com/repos/ipython/traitlets/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/ipython/traitlets/downloads","issues_url":"https://api.github.com/repos/ipython/traitlets/issues{/number}","pulls_url":"https://api.github.com/repos/ipython/traitlets/pulls{/number}","milestones_url":"https://api.github.com/repos/ipython/traitlets/milestones{/number}","notifications_url":"https://api.github.com/repos/ipython/traitlets/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/ipython/traitlets/labels{/name}","releases_url":"https://api.github.com/repos/ipython/traitlets/releases{/id}","created_at":"2013-12-06T20:45:45Z","updated_at":"2015-11-10T06:54:01Z","pushed_at":"2015-12-01T05:14:50Z","git_url":"git://github.com/ipython/traitlets.git","ssh_url":"git@github.com:ipython/traitlets.git","clone_url":"https://github.com/ipython/traitlets.git","svn_url":"https://github.com/ipython/traitlets","homepage":"http://traitlets.readthedocs.org/","size":1745,"stargazers_count":28,"watchers_count":28,"language":"Python","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":33,"mirror_url":null,"open_issues_count":21,"forks":33,"open_issues":21,"watchers":28,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/ipython/traitlets/pulls/140"},"html":{"href":"https://github.com/ipython/traitlets/pull/140"},"issue":{"href":"https://api.github.com/repos/ipython/traitlets/issues/140"},"comments":{"href":"https://api.github.com/repos/ipython/traitlets/issues/140/comments"},"review_comments":{"href":"https://api.github.com/repos/ipython/traitlets/pulls/140/comments"},"review_comment":{"href":"https://api.github.com/repos/ipython/traitlets/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/ipython/traitlets/pulls/140/commits"},"statuses":{"href":"https://api.github.com/repos/ipython/traitlets/statuses/a40c0bd1feba2eebfd8088f11eead83a0e85db29"}},"merged":false,"mergeable":null,"mergeable_state":"unknown","merged_by":null,"comments":0,"review_comments":0,"commits":0,"additions":0,"deletions":0,"changed_files":0}}