{"action":"created","comment":{"url":"https://api.github.com/repos/graphql/graphql-js/pulls/comments/85845891","pull_request_review_id":6536921,"id":85845891,"diff_hunk":"@@ -68,11 +71,19 @@ export function astFromValue(\n   const _value = value;\n \n   if (type instanceof GraphQLNonNull) {\n-    // Note: we're not checking that the result is non-null.\n-    // This function is not responsible for validating the input value.\n-    return astFromValue(_value, type.ofType);\n+    const astValue = astFromValue(_value, type.ofType);\n+    if (astValue && astValue.kind === NULL) {\n+      return null;\n+    }\n+    return astValue;\n+  }\n+\n+  // only explicit null, not undefined, NaN\n+  if (_value === null) {\n+    return ({ kind: NULL }: NullValue);\n   }\n \n+  // other nullish values\n   if (isNullish(_value)) {","path":"src/utilities/astFromValue.js","position":44,"original_position":44,"commit_id":"07ac6d7c3c2b9add09d9f4cb45c7049f2b95b019","original_commit_id":"1c29b5de4031f2eb95187281dd641dd339709291","user":{"login":"leebyron","id":50130,"avatar_url":"https://avatars.githubusercontent.com/u/50130?v=3","gravatar_id":"","url":"https://api.github.com/users/leebyron","html_url":"https://github.com/leebyron","followers_url":"https://api.github.com/users/leebyron/followers","following_url":"https://api.github.com/users/leebyron/following{/other_user}","gists_url":"https://api.github.com/users/leebyron/gists{/gist_id}","starred_url":"https://api.github.com/users/leebyron/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/leebyron/subscriptions","organizations_url":"https://api.github.com/users/leebyron/orgs","repos_url":"https://api.github.com/users/leebyron/repos","events_url":"https://api.github.com/users/leebyron/events{/privacy}","received_events_url":"https://api.github.com/users/leebyron/received_events","type":"User","site_admin":false},"body":"perhaps use your new `isInvalid` function here?","created_at":"2016-10-31T22:24:09Z","updated_at":"2016-10-31T22:35:57Z","html_url":"https://github.com/graphql/graphql-js/pull/544#discussion_r85845891","pull_request_url":"https://api.github.com/repos/graphql/graphql-js/pulls/544","_links":{"self":{"href":"https://api.github.com/repos/graphql/graphql-js/pulls/comments/85845891"},"html":{"href":"https://github.com/graphql/graphql-js/pull/544#discussion_r85845891"},"pull_request":{"href":"https://api.github.com/repos/graphql/graphql-js/pulls/544"}}},"pull_request":{"url":"https://api.github.com/repos/graphql/graphql-js/pulls/544","id":91176939,"html_url":"https://github.com/graphql/graphql-js/pull/544","diff_url":"https://github.com/graphql/graphql-js/pull/544.diff","patch_url":"https://github.com/graphql/graphql-js/pull/544.patch","issue_url":"https://api.github.com/repos/graphql/graphql-js/issues/544","number":544,"state":"open","locked":false,"title":"language support for NullValue","user":{"login":"langpavel","id":142462,"avatar_url":"https://avatars.githubusercontent.com/u/142462?v=3","gravatar_id":"","url":"https://api.github.com/users/langpavel","html_url":"https://github.com/langpavel","followers_url":"https://api.github.com/users/langpavel/followers","following_url":"https://api.github.com/users/langpavel/following{/other_user}","gists_url":"https://api.github.com/users/langpavel/gists{/gist_id}","starred_url":"https://api.github.com/users/langpavel/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/langpavel/subscriptions","organizations_url":"https://api.github.com/users/langpavel/orgs","repos_url":"https://api.github.com/users/langpavel/repos","events_url":"https://api.github.com/users/langpavel/events{/privacy}","received_events_url":"https://api.github.com/users/langpavel/received_events","type":"User","site_admin":false},"body":"Work in progress [GraphQL RFC: Null value](https://github.com/facebook/graphql/pull/83/files)\n- [x] Support `null` literal in Parser\n- [x] Support `null` literal in Printer\n- [x] `astFromValue`\n- [x] `valueFromAST`\n- [x] `getArgumentValues`, `getVariableValue` in **execution/values.js**\n- [x] `isValidLiteralValue` in **utilities/isValidLiteralValue.js**\n- [x] introspection of `__InputValue defaultValue` field in **type/introspection.js**\n- [x] **utilities/schemaPrinter.js**\n- [ ] _some more tests_\n","created_at":"2016-10-27T10:54:18Z","updated_at":"2016-10-31T22:35:57Z","closed_at":null,"merged_at":null,"merge_commit_sha":"2f28f788a027fd83405ab9253df5408ad6ce7a94","assignee":null,"assignees":[],"milestone":null,"commits_url":"https://api.github.com/repos/graphql/graphql-js/pulls/544/commits","review_comments_url":"https://api.github.com/repos/graphql/graphql-js/pulls/544/comments","review_comment_url":"https://api.github.com/repos/graphql/graphql-js/pulls/comments{/number}","comments_url":"https://api.github.com/repos/graphql/graphql-js/issues/544/comments","statuses_url":"https://api.github.com/repos/graphql/graphql-js/statuses/07ac6d7c3c2b9add09d9f4cb45c7049f2b95b019","head":{"label":"langpavel:graphql-null-83","ref":"graphql-null-83","sha":"07ac6d7c3c2b9add09d9f4cb45c7049f2b95b019","user":{"login":"langpavel","id":142462,"avatar_url":"https://avatars.githubusercontent.com/u/142462?v=3","gravatar_id":"","url":"https://api.github.com/users/langpavel","html_url":"https://github.com/langpavel","followers_url":"https://api.github.com/users/langpavel/followers","following_url":"https://api.github.com/users/langpavel/following{/other_user}","gists_url":"https://api.github.com/users/langpavel/gists{/gist_id}","starred_url":"https://api.github.com/users/langpavel/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/langpavel/subscriptions","organizations_url":"https://api.github.com/users/langpavel/orgs","repos_url":"https://api.github.com/users/langpavel/repos","events_url":"https://api.github.com/users/langpavel/events{/privacy}","received_events_url":"https://api.github.com/users/langpavel/received_events","type":"User","site_admin":false},"repo":{"id":70749171,"name":"graphql-js","full_name":"langpavel/graphql-js","owner":{"login":"langpavel","id":142462,"avatar_url":"https://avatars.githubusercontent.com/u/142462?v=3","gravatar_id":"","url":"https://api.github.com/users/langpavel","html_url":"https://github.com/langpavel","followers_url":"https://api.github.com/users/langpavel/followers","following_url":"https://api.github.com/users/langpavel/following{/other_user}","gists_url":"https://api.github.com/users/langpavel/gists{/gist_id}","starred_url":"https://api.github.com/users/langpavel/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/langpavel/subscriptions","organizations_url":"https://api.github.com/users/langpavel/orgs","repos_url":"https://api.github.com/users/langpavel/repos","events_url":"https://api.github.com/users/langpavel/events{/privacy}","received_events_url":"https://api.github.com/users/langpavel/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/langpavel/graphql-js","description":"A reference implementation of GraphQL for JavaScript","fork":true,"url":"https://api.github.com/repos/langpavel/graphql-js","forks_url":"https://api.github.com/repos/langpavel/graphql-js/forks","keys_url":"https://api.github.com/repos/langpavel/graphql-js/keys{/key_id}","collaborators_url":"https://api.github.com/repos/langpavel/graphql-js/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/langpavel/graphql-js/teams","hooks_url":"https://api.github.com/repos/langpavel/graphql-js/hooks","issue_events_url":"https://api.github.com/repos/langpavel/graphql-js/issues/events{/number}","events_url":"https://api.github.com/repos/langpavel/graphql-js/events","assignees_url":"https://api.github.com/repos/langpavel/graphql-js/assignees{/user}","branches_url":"https://api.github.com/repos/langpavel/graphql-js/branches{/branch}","tags_url":"https://api.github.com/repos/langpavel/graphql-js/tags","blobs_url":"https://api.github.com/repos/langpavel/graphql-js/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/langpavel/graphql-js/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/langpavel/graphql-js/git/refs{/sha}","trees_url":"https://api.github.com/repos/langpavel/graphql-js/git/trees{/sha}","statuses_url":"https://api.github.com/repos/langpavel/graphql-js/statuses/{sha}","languages_url":"https://api.github.com/repos/langpavel/graphql-js/languages","stargazers_url":"https://api.github.com/repos/langpavel/graphql-js/stargazers","contributors_url":"https://api.github.com/repos/langpavel/graphql-js/contributors","subscribers_url":"https://api.github.com/repos/langpavel/graphql-js/subscribers","subscription_url":"https://api.github.com/repos/langpavel/graphql-js/subscription","commits_url":"https://api.github.com/repos/langpavel/graphql-js/commits{/sha}","git_commits_url":"https://api.github.com/repos/langpavel/graphql-js/git/commits{/sha}","comments_url":"https://api.github.com/repos/langpavel/graphql-js/comments{/number}","issue_comment_url":"https://api.github.com/repos/langpavel/graphql-js/issues/comments{/number}","contents_url":"https://api.github.com/repos/langpavel/graphql-js/contents/{+path}","compare_url":"https://api.github.com/repos/langpavel/graphql-js/compare/{base}...{head}","merges_url":"https://api.github.com/repos/langpavel/graphql-js/merges","archive_url":"https://api.github.com/repos/langpavel/graphql-js/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/langpavel/graphql-js/downloads","issues_url":"https://api.github.com/repos/langpavel/graphql-js/issues{/number}","pulls_url":"https://api.github.com/repos/langpavel/graphql-js/pulls{/number}","milestones_url":"https://api.github.com/repos/langpavel/graphql-js/milestones{/number}","notifications_url":"https://api.github.com/repos/langpavel/graphql-js/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/langpavel/graphql-js/labels{/name}","releases_url":"https://api.github.com/repos/langpavel/graphql-js/releases{/id}","deployments_url":"https://api.github.com/repos/langpavel/graphql-js/deployments","created_at":"2016-10-12T23:09:02Z","updated_at":"2016-10-12T23:09:04Z","pushed_at":"2016-10-31T22:33:26Z","git_url":"git://github.com/langpavel/graphql-js.git","ssh_url":"git@github.com:langpavel/graphql-js.git","clone_url":"https://github.com/langpavel/graphql-js.git","svn_url":"https://github.com/langpavel/graphql-js","homepage":"http://graphql.org/graphql-js/","size":1511,"stargazers_count":0,"watchers_count":0,"language":"JavaScript","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":"graphql:master","ref":"master","sha":"bc96406ab44453a120da25a0bd6e2b0237119ddf","user":{"login":"graphql","id":12972006,"avatar_url":"https://avatars.githubusercontent.com/u/12972006?v=3","gravatar_id":"","url":"https://api.github.com/users/graphql","html_url":"https://github.com/graphql","followers_url":"https://api.github.com/users/graphql/followers","following_url":"https://api.github.com/users/graphql/following{/other_user}","gists_url":"https://api.github.com/users/graphql/gists{/gist_id}","starred_url":"https://api.github.com/users/graphql/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/graphql/subscriptions","organizations_url":"https://api.github.com/users/graphql/orgs","repos_url":"https://api.github.com/users/graphql/repos","events_url":"https://api.github.com/users/graphql/events{/privacy}","received_events_url":"https://api.github.com/users/graphql/received_events","type":"Organization","site_admin":false},"repo":{"id":38307428,"name":"graphql-js","full_name":"graphql/graphql-js","owner":{"login":"graphql","id":12972006,"avatar_url":"https://avatars.githubusercontent.com/u/12972006?v=3","gravatar_id":"","url":"https://api.github.com/users/graphql","html_url":"https://github.com/graphql","followers_url":"https://api.github.com/users/graphql/followers","following_url":"https://api.github.com/users/graphql/following{/other_user}","gists_url":"https://api.github.com/users/graphql/gists{/gist_id}","starred_url":"https://api.github.com/users/graphql/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/graphql/subscriptions","organizations_url":"https://api.github.com/users/graphql/orgs","repos_url":"https://api.github.com/users/graphql/repos","events_url":"https://api.github.com/users/graphql/events{/privacy}","received_events_url":"https://api.github.com/users/graphql/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/graphql/graphql-js","description":"A reference implementation of GraphQL for JavaScript","fork":false,"url":"https://api.github.com/repos/graphql/graphql-js","forks_url":"https://api.github.com/repos/graphql/graphql-js/forks","keys_url":"https://api.github.com/repos/graphql/graphql-js/keys{/key_id}","collaborators_url":"https://api.github.com/repos/graphql/graphql-js/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/graphql/graphql-js/teams","hooks_url":"https://api.github.com/repos/graphql/graphql-js/hooks","issue_events_url":"https://api.github.com/repos/graphql/graphql-js/issues/events{/number}","events_url":"https://api.github.com/repos/graphql/graphql-js/events","assignees_url":"https://api.github.com/repos/graphql/graphql-js/assignees{/user}","branches_url":"https://api.github.com/repos/graphql/graphql-js/branches{/branch}","tags_url":"https://api.github.com/repos/graphql/graphql-js/tags","blobs_url":"https://api.github.com/repos/graphql/graphql-js/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/graphql/graphql-js/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/graphql/graphql-js/git/refs{/sha}","trees_url":"https://api.github.com/repos/graphql/graphql-js/git/trees{/sha}","statuses_url":"https://api.github.com/repos/graphql/graphql-js/statuses/{sha}","languages_url":"https://api.github.com/repos/graphql/graphql-js/languages","stargazers_url":"https://api.github.com/repos/graphql/graphql-js/stargazers","contributors_url":"https://api.github.com/repos/graphql/graphql-js/contributors","subscribers_url":"https://api.github.com/repos/graphql/graphql-js/subscribers","subscription_url":"https://api.github.com/repos/graphql/graphql-js/subscription","commits_url":"https://api.github.com/repos/graphql/graphql-js/commits{/sha}","git_commits_url":"https://api.github.com/repos/graphql/graphql-js/git/commits{/sha}","comments_url":"https://api.github.com/repos/graphql/graphql-js/comments{/number}","issue_comment_url":"https://api.github.com/repos/graphql/graphql-js/issues/comments{/number}","contents_url":"https://api.github.com/repos/graphql/graphql-js/contents/{+path}","compare_url":"https://api.github.com/repos/graphql/graphql-js/compare/{base}...{head}","merges_url":"https://api.github.com/repos/graphql/graphql-js/merges","archive_url":"https://api.github.com/repos/graphql/graphql-js/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/graphql/graphql-js/downloads","issues_url":"https://api.github.com/repos/graphql/graphql-js/issues{/number}","pulls_url":"https://api.github.com/repos/graphql/graphql-js/pulls{/number}","milestones_url":"https://api.github.com/repos/graphql/graphql-js/milestones{/number}","notifications_url":"https://api.github.com/repos/graphql/graphql-js/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/graphql/graphql-js/labels{/name}","releases_url":"https://api.github.com/repos/graphql/graphql-js/releases{/id}","deployments_url":"https://api.github.com/repos/graphql/graphql-js/deployments","created_at":"2015-06-30T12:16:50Z","updated_at":"2016-10-31T21:25:19Z","pushed_at":"2016-10-31T22:33:27Z","git_url":"git://github.com/graphql/graphql-js.git","ssh_url":"git@github.com:graphql/graphql-js.git","clone_url":"https://github.com/graphql/graphql-js.git","svn_url":"https://github.com/graphql/graphql-js","homepage":"http://graphql.org/graphql-js/","size":1876,"stargazers_count":4834,"watchers_count":4834,"language":"JavaScript","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":352,"mirror_url":null,"open_issues_count":67,"forks":352,"open_issues":67,"watchers":4834,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/graphql/graphql-js/pulls/544"},"html":{"href":"https://github.com/graphql/graphql-js/pull/544"},"issue":{"href":"https://api.github.com/repos/graphql/graphql-js/issues/544"},"comments":{"href":"https://api.github.com/repos/graphql/graphql-js/issues/544/comments"},"review_comments":{"href":"https://api.github.com/repos/graphql/graphql-js/pulls/544/comments"},"review_comment":{"href":"https://api.github.com/repos/graphql/graphql-js/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/graphql/graphql-js/pulls/544/commits"},"statuses":{"href":"https://api.github.com/repos/graphql/graphql-js/statuses/07ac6d7c3c2b9add09d9f4cb45c7049f2b95b019"}}}}
{"actor":{"display_login":"leebyron"}}