{"action":"created","comment":{"url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/pulls/comments/35838827","id":35838827,"diff_hunk":"@@ -123,11 +123,7 @@ func (s *SwaggerSchema) ValidateObject(obj interface{}, apiVersion, fieldName, t\n \tfor key, value := range fields {\n \t\tdetails, ok := properties.At(key)\n \t\tif !ok {\n-\t\t\tglog.Infof(\"unknown field: %s\", key)\n-\t\t\t// Some properties can be missing because of\n-\t\t\t// https://github.com/GoogleCloudPlatform/kubernetes/issues/6842.\n-\t\t\tglog.Info(\"this may be a false alarm, see https://github.com/GoogleCloudPlatform/kubernetes/issues/6842\")\n-\t\t\tcontinue\n+\t\t\treturn append(allErrs, fmt.Errorf(\"found invalid field %s for %s\", key, typeName))","path":"pkg/api/validation/schema.go","position":18,"original_position":18,"commit_id":"e31abe2172c28e38cf25b315e5536157ee2dd6cc","original_commit_id":"e31abe2172c28e38cf25b315e5536157ee2dd6cc","user":{"login":"bgrant0607","id":7725777,"avatar_url":"https://avatars.githubusercontent.com/u/7725777?v=3","gravatar_id":"","url":"https://api.github.com/users/bgrant0607","html_url":"https://github.com/bgrant0607","followers_url":"https://api.github.com/users/bgrant0607/followers","following_url":"https://api.github.com/users/bgrant0607/following{/other_user}","gists_url":"https://api.github.com/users/bgrant0607/gists{/gist_id}","starred_url":"https://api.github.com/users/bgrant0607/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bgrant0607/subscriptions","organizations_url":"https://api.github.com/users/bgrant0607/orgs","repos_url":"https://api.github.com/users/bgrant0607/repos","events_url":"https://api.github.com/users/bgrant0607/events{/privacy}","received_events_url":"https://api.github.com/users/bgrant0607/received_events","type":"User","site_admin":false},"body":"It's not the same case as line 103. We don't need to look at details.\r\n\r\nWhy can't we move on to the next field? That's what the code was doing before.","created_at":"2015-07-30T05:16:32Z","updated_at":"2015-07-30T05:16:32Z","html_url":"https://github.com/GoogleCloudPlatform/kubernetes/pull/11914#discussion_r35838827","pull_request_url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/pulls/11914","_links":{"self":{"href":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/pulls/comments/35838827"},"html":{"href":"https://github.com/GoogleCloudPlatform/kubernetes/pull/11914#discussion_r35838827"},"pull_request":{"href":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/pulls/11914"}}},"pull_request":{"url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/pulls/11914","id":40966084,"html_url":"https://github.com/GoogleCloudPlatform/kubernetes/pull/11914","diff_url":"https://github.com/GoogleCloudPlatform/kubernetes/pull/11914.diff","patch_url":"https://github.com/GoogleCloudPlatform/kubernetes/pull/11914.patch","issue_url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/issues/11914","number":11914,"state":"open","locked":false,"title":"Swagger validation: stop ignoring unknown fields","user":{"login":"nikhiljindal","id":10199099,"avatar_url":"https://avatars.githubusercontent.com/u/10199099?v=3","gravatar_id":"","url":"https://api.github.com/users/nikhiljindal","html_url":"https://github.com/nikhiljindal","followers_url":"https://api.github.com/users/nikhiljindal/followers","following_url":"https://api.github.com/users/nikhiljindal/following{/other_user}","gists_url":"https://api.github.com/users/nikhiljindal/gists{/gist_id}","starred_url":"https://api.github.com/users/nikhiljindal/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nikhiljindal/subscriptions","organizations_url":"https://api.github.com/users/nikhiljindal/orgs","repos_url":"https://api.github.com/users/nikhiljindal/repos","events_url":"https://api.github.com/users/nikhiljindal/events{/privacy}","received_events_url":"https://api.github.com/users/nikhiljindal/received_events","type":"User","site_admin":false},"body":"Fixes https://github.com/GoogleCloudPlatform/kubernetes/issues/6842.\r\n\r\nWe were ignoring fields from user-specified json/yaml, that were not present in swagger-spec, due to the spec being incomplete.\r\nWe shouldnt be ignoring them any longer.\r\n\r\nFor ex, for following pod.yaml:\r\n```\r\napiVersion: v1\r\nkind: Pod\r\n\r\n\r\nfsd:fasd\r\n\r\n```\r\n```\r\n$kubectl create -f pod.yaml --validate\r\n```\r\nBefore:\r\nsuccessful creation.\r\nAfter:\r\n```\r\nerror validating data: found invalid field fsd for v1.Pod\r\n```","created_at":"2015-07-28T00:57:30Z","updated_at":"2015-07-30T05:16:32Z","closed_at":null,"merged_at":null,"merge_commit_sha":"1451352ae8caa4ac428659fc3664ff97bff0c03b","assignee":{"login":"bgrant0607","id":7725777,"avatar_url":"https://avatars.githubusercontent.com/u/7725777?v=3","gravatar_id":"","url":"https://api.github.com/users/bgrant0607","html_url":"https://github.com/bgrant0607","followers_url":"https://api.github.com/users/bgrant0607/followers","following_url":"https://api.github.com/users/bgrant0607/following{/other_user}","gists_url":"https://api.github.com/users/bgrant0607/gists{/gist_id}","starred_url":"https://api.github.com/users/bgrant0607/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bgrant0607/subscriptions","organizations_url":"https://api.github.com/users/bgrant0607/orgs","repos_url":"https://api.github.com/users/bgrant0607/repos","events_url":"https://api.github.com/users/bgrant0607/events{/privacy}","received_events_url":"https://api.github.com/users/bgrant0607/received_events","type":"User","site_admin":false},"milestone":null,"commits_url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/pulls/11914/commits","review_comments_url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/pulls/11914/comments","review_comment_url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/pulls/comments{/number}","comments_url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/issues/11914/comments","statuses_url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/statuses/e31abe2172c28e38cf25b315e5536157ee2dd6cc","head":{"label":"nikhiljindal:missingSwagger","ref":"missingSwagger","sha":"e31abe2172c28e38cf25b315e5536157ee2dd6cc","user":{"login":"nikhiljindal","id":10199099,"avatar_url":"https://avatars.githubusercontent.com/u/10199099?v=3","gravatar_id":"","url":"https://api.github.com/users/nikhiljindal","html_url":"https://github.com/nikhiljindal","followers_url":"https://api.github.com/users/nikhiljindal/followers","following_url":"https://api.github.com/users/nikhiljindal/following{/other_user}","gists_url":"https://api.github.com/users/nikhiljindal/gists{/gist_id}","starred_url":"https://api.github.com/users/nikhiljindal/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nikhiljindal/subscriptions","organizations_url":"https://api.github.com/users/nikhiljindal/orgs","repos_url":"https://api.github.com/users/nikhiljindal/repos","events_url":"https://api.github.com/users/nikhiljindal/events{/privacy}","received_events_url":"https://api.github.com/users/nikhiljindal/received_events","type":"User","site_admin":false},"repo":{"id":29988055,"name":"kubernetes","full_name":"nikhiljindal/kubernetes","owner":{"login":"nikhiljindal","id":10199099,"avatar_url":"https://avatars.githubusercontent.com/u/10199099?v=3","gravatar_id":"","url":"https://api.github.com/users/nikhiljindal","html_url":"https://github.com/nikhiljindal","followers_url":"https://api.github.com/users/nikhiljindal/followers","following_url":"https://api.github.com/users/nikhiljindal/following{/other_user}","gists_url":"https://api.github.com/users/nikhiljindal/gists{/gist_id}","starred_url":"https://api.github.com/users/nikhiljindal/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nikhiljindal/subscriptions","organizations_url":"https://api.github.com/users/nikhiljindal/orgs","repos_url":"https://api.github.com/users/nikhiljindal/repos","events_url":"https://api.github.com/users/nikhiljindal/events{/privacy}","received_events_url":"https://api.github.com/users/nikhiljindal/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/nikhiljindal/kubernetes","description":"Container Cluster Manager","fork":true,"url":"https://api.github.com/repos/nikhiljindal/kubernetes","forks_url":"https://api.github.com/repos/nikhiljindal/kubernetes/forks","keys_url":"https://api.github.com/repos/nikhiljindal/kubernetes/keys{/key_id}","collaborators_url":"https://api.github.com/repos/nikhiljindal/kubernetes/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/nikhiljindal/kubernetes/teams","hooks_url":"https://api.github.com/repos/nikhiljindal/kubernetes/hooks","issue_events_url":"https://api.github.com/repos/nikhiljindal/kubernetes/issues/events{/number}","events_url":"https://api.github.com/repos/nikhiljindal/kubernetes/events","assignees_url":"https://api.github.com/repos/nikhiljindal/kubernetes/assignees{/user}","branches_url":"https://api.github.com/repos/nikhiljindal/kubernetes/branches{/branch}","tags_url":"https://api.github.com/repos/nikhiljindal/kubernetes/tags","blobs_url":"https://api.github.com/repos/nikhiljindal/kubernetes/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/nikhiljindal/kubernetes/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/nikhiljindal/kubernetes/git/refs{/sha}","trees_url":"https://api.github.com/repos/nikhiljindal/kubernetes/git/trees{/sha}","statuses_url":"https://api.github.com/repos/nikhiljindal/kubernetes/statuses/{sha}","languages_url":"https://api.github.com/repos/nikhiljindal/kubernetes/languages","stargazers_url":"https://api.github.com/repos/nikhiljindal/kubernetes/stargazers","contributors_url":"https://api.github.com/repos/nikhiljindal/kubernetes/contributors","subscribers_url":"https://api.github.com/repos/nikhiljindal/kubernetes/subscribers","subscription_url":"https://api.github.com/repos/nikhiljindal/kubernetes/subscription","commits_url":"https://api.github.com/repos/nikhiljindal/kubernetes/commits{/sha}","git_commits_url":"https://api.github.com/repos/nikhiljindal/kubernetes/git/commits{/sha}","comments_url":"https://api.github.com/repos/nikhiljindal/kubernetes/comments{/number}","issue_comment_url":"https://api.github.com/repos/nikhiljindal/kubernetes/issues/comments{/number}","contents_url":"https://api.github.com/repos/nikhiljindal/kubernetes/contents/{+path}","compare_url":"https://api.github.com/repos/nikhiljindal/kubernetes/compare/{base}...{head}","merges_url":"https://api.github.com/repos/nikhiljindal/kubernetes/merges","archive_url":"https://api.github.com/repos/nikhiljindal/kubernetes/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/nikhiljindal/kubernetes/downloads","issues_url":"https://api.github.com/repos/nikhiljindal/kubernetes/issues{/number}","pulls_url":"https://api.github.com/repos/nikhiljindal/kubernetes/pulls{/number}","milestones_url":"https://api.github.com/repos/nikhiljindal/kubernetes/milestones{/number}","notifications_url":"https://api.github.com/repos/nikhiljindal/kubernetes/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/nikhiljindal/kubernetes/labels{/name}","releases_url":"https://api.github.com/repos/nikhiljindal/kubernetes/releases{/id}","created_at":"2015-01-28T21:01:50Z","updated_at":"2015-01-28T21:01:53Z","pushed_at":"2015-07-29T17:31:52Z","git_url":"git://github.com/nikhiljindal/kubernetes.git","ssh_url":"git@github.com:nikhiljindal/kubernetes.git","clone_url":"https://github.com/nikhiljindal/kubernetes.git","svn_url":"https://github.com/nikhiljindal/kubernetes","homepage":"http://kubernetes.io","size":95314,"stargazers_count":0,"watchers_count":0,"language":"Go","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":true,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"GoogleCloudPlatform:master","ref":"master","sha":"c5bffaaf3166513da6259c44a5d1ba8e86bea5ce","user":{"login":"GoogleCloudPlatform","id":2810941,"avatar_url":"https://avatars.githubusercontent.com/u/2810941?v=3","gravatar_id":"","url":"https://api.github.com/users/GoogleCloudPlatform","html_url":"https://github.com/GoogleCloudPlatform","followers_url":"https://api.github.com/users/GoogleCloudPlatform/followers","following_url":"https://api.github.com/users/GoogleCloudPlatform/following{/other_user}","gists_url":"https://api.github.com/users/GoogleCloudPlatform/gists{/gist_id}","starred_url":"https://api.github.com/users/GoogleCloudPlatform/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/GoogleCloudPlatform/subscriptions","organizations_url":"https://api.github.com/users/GoogleCloudPlatform/orgs","repos_url":"https://api.github.com/users/GoogleCloudPlatform/repos","events_url":"https://api.github.com/users/GoogleCloudPlatform/events{/privacy}","received_events_url":"https://api.github.com/users/GoogleCloudPlatform/received_events","type":"Organization","site_admin":false},"repo":{"id":20580498,"name":"kubernetes","full_name":"GoogleCloudPlatform/kubernetes","owner":{"login":"GoogleCloudPlatform","id":2810941,"avatar_url":"https://avatars.githubusercontent.com/u/2810941?v=3","gravatar_id":"","url":"https://api.github.com/users/GoogleCloudPlatform","html_url":"https://github.com/GoogleCloudPlatform","followers_url":"https://api.github.com/users/GoogleCloudPlatform/followers","following_url":"https://api.github.com/users/GoogleCloudPlatform/following{/other_user}","gists_url":"https://api.github.com/users/GoogleCloudPlatform/gists{/gist_id}","starred_url":"https://api.github.com/users/GoogleCloudPlatform/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/GoogleCloudPlatform/subscriptions","organizations_url":"https://api.github.com/users/GoogleCloudPlatform/orgs","repos_url":"https://api.github.com/users/GoogleCloudPlatform/repos","events_url":"https://api.github.com/users/GoogleCloudPlatform/events{/privacy}","received_events_url":"https://api.github.com/users/GoogleCloudPlatform/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/GoogleCloudPlatform/kubernetes","description":"Container Cluster Manager from Google","fork":false,"url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes","forks_url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/forks","keys_url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/keys{/key_id}","collaborators_url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/teams","hooks_url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/hooks","issue_events_url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/issues/events{/number}","events_url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/events","assignees_url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/assignees{/user}","branches_url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/branches{/branch}","tags_url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/tags","blobs_url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/git/refs{/sha}","trees_url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/git/trees{/sha}","statuses_url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/statuses/{sha}","languages_url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/languages","stargazers_url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/stargazers","contributors_url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/contributors","subscribers_url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/subscribers","subscription_url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/subscription","commits_url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/commits{/sha}","git_commits_url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/git/commits{/sha}","comments_url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/comments{/number}","issue_comment_url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/issues/comments{/number}","contents_url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/contents/{+path}","compare_url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/compare/{base}...{head}","merges_url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/merges","archive_url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/downloads","issues_url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/issues{/number}","pulls_url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/pulls{/number}","milestones_url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/milestones{/number}","notifications_url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/labels{/name}","releases_url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/releases{/id}","created_at":"2014-06-06T22:56:04Z","updated_at":"2015-07-30T04:24:30Z","pushed_at":"2015-07-30T04:55:50Z","git_url":"git://github.com/GoogleCloudPlatform/kubernetes.git","ssh_url":"git@github.com:GoogleCloudPlatform/kubernetes.git","clone_url":"https://github.com/GoogleCloudPlatform/kubernetes.git","svn_url":"https://github.com/GoogleCloudPlatform/kubernetes","homepage":"http://kubernetes.io","size":333088,"stargazers_count":9448,"watchers_count":9448,"language":"Go","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":true,"forks_count":2183,"mirror_url":null,"open_issues_count":1670,"forks":2183,"open_issues":1670,"watchers":9448,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/pulls/11914"},"html":{"href":"https://github.com/GoogleCloudPlatform/kubernetes/pull/11914"},"issue":{"href":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/issues/11914"},"comments":{"href":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/issues/11914/comments"},"review_comments":{"href":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/pulls/11914/comments"},"review_comment":{"href":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/pulls/11914/commits"},"statuses":{"href":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/statuses/e31abe2172c28e38cf25b315e5536157ee2dd6cc"}}}}