{"action":"created","comment":{"url":"https://api.github.com/repos/grpc/grpc/pulls/comments/84979628","pull_request_review_id":5723145,"id":84979628,"diff_hunk":"@@ -44,25 +44,48 @@\n from src.proto.grpc.testing import messages_pb2\n from src.proto.grpc.testing import test_pb2\n \n+_INITIAL_METADATA_KEY = \"x-grpc-test-echo-initial\"\n+_TRAILING_METADATA_KEY = \"x-grpc-test-echo-trailing-bin\"\n+\n+# If the request came with metadata in the context, this\n+# helper function will copy it to the returned metadata.\n+def _maybe_echo_metadata(context):\n+  metadata = dict(context.invocation_metadata())\n+  if _INITIAL_METADATA_KEY in metadata:\n+    initial_metadata = (\n+        _INITIAL_METADATA_KEY, metadata[_INITIAL_METADATA_KEY])\n+    # Send initial metadata expects a list of tuples\n+    context.send_initial_metadata([initial_metadata])\n+  if _TRAILING_METADATA_KEY in metadata:\n+    trailing_metadata = (\n+      _TRAILING_METADATA_KEY, metadata[_TRAILING_METADATA_KEY])\n+    # Set trailing metadata expects a list of tuples\n+    context.set_trailing_metadata([trailing_metadata])\n+\n+# If the request asks for a particular status code and details, this helper","path":"src/python/grpcio_tests/tests/interop/methods.py","position":22,"original_position":22,"commit_id":"cbddcdf54ccb07403c309fa0bcf47cf85bcde71b","original_commit_id":"cbddcdf54ccb07403c309fa0bcf47cf85bcde71b","user":{"login":"nathanielmanistaatgoogle","id":10131044,"avatar_url":"https://avatars.githubusercontent.com/u/10131044?v=3","gravatar_id":"","url":"https://api.github.com/users/nathanielmanistaatgoogle","html_url":"https://github.com/nathanielmanistaatgoogle","followers_url":"https://api.github.com/users/nathanielmanistaatgoogle/followers","following_url":"https://api.github.com/users/nathanielmanistaatgoogle/following{/other_user}","gists_url":"https://api.github.com/users/nathanielmanistaatgoogle/gists{/gist_id}","starred_url":"https://api.github.com/users/nathanielmanistaatgoogle/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nathanielmanistaatgoogle/subscriptions","organizations_url":"https://api.github.com/users/nathanielmanistaatgoogle/orgs","repos_url":"https://api.github.com/users/nathanielmanistaatgoogle/repos","events_url":"https://api.github.com/users/nathanielmanistaatgoogle/events{/privacy}","received_events_url":"https://api.github.com/users/nathanielmanistaatgoogle/received_events","type":"User","site_admin":false},"body":"How about a doc string here too?","created_at":"2016-10-25T19:16:33Z","updated_at":"2016-10-25T19:16:33Z","html_url":"https://github.com/grpc/grpc/pull/8449#discussion_r84979628","pull_request_url":"https://api.github.com/repos/grpc/grpc/pulls/8449","_links":{"self":{"href":"https://api.github.com/repos/grpc/grpc/pulls/comments/84979628"},"html":{"href":"https://github.com/grpc/grpc/pull/8449#discussion_r84979628"},"pull_request":{"href":"https://api.github.com/repos/grpc/grpc/pulls/8449"}}},"pull_request":{"url":"https://api.github.com/repos/grpc/grpc/pulls/8449","id":90311016,"html_url":"https://github.com/grpc/grpc/pull/8449","diff_url":"https://github.com/grpc/grpc/pull/8449.diff","patch_url":"https://github.com/grpc/grpc/pull/8449.patch","issue_url":"https://api.github.com/repos/grpc/grpc/issues/8449","number":8449,"state":"open","locked":false,"title":"New python interop tests","user":{"login":"ncteisen","id":6148140,"avatar_url":"https://avatars.githubusercontent.com/u/6148140?v=3","gravatar_id":"","url":"https://api.github.com/users/ncteisen","html_url":"https://github.com/ncteisen","followers_url":"https://api.github.com/users/ncteisen/followers","following_url":"https://api.github.com/users/ncteisen/following{/other_user}","gists_url":"https://api.github.com/users/ncteisen/gists{/gist_id}","starred_url":"https://api.github.com/users/ncteisen/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ncteisen/subscriptions","organizations_url":"https://api.github.com/users/ncteisen/orgs","repos_url":"https://api.github.com/users/ncteisen/repos","events_url":"https://api.github.com/users/ncteisen/events{/privacy}","received_events_url":"https://api.github.com/users/ncteisen/received_events","type":"User","site_admin":false},"body":"Implemented two new interop tests for the python client: unimplemented_method and custom_metadata. Also cleaned and fixed status_code_and_message (it was using StreamingOutputCall instead of FullDuplexCall and it was never even validated the results of the StreamingOutputCall).\r\n\r\nAlso implemented python interop server behavior to echo custom metadata.\r\n\r\nHad to make a small change to the node interop client removing the check on the error message sent when a client calls an unimplemented method. Most servers return null string, python returns \"Method not found!\" Will fix this discrepancy in a future PR","created_at":"2016-10-21T01:51:53Z","updated_at":"2016-10-25T19:28:48Z","closed_at":null,"merged_at":null,"merge_commit_sha":"e4397ea9e97501777d4a186c6029fd0a9ca0b17e","assignee":{"login":"nathanielmanistaatgoogle","id":10131044,"avatar_url":"https://avatars.githubusercontent.com/u/10131044?v=3","gravatar_id":"","url":"https://api.github.com/users/nathanielmanistaatgoogle","html_url":"https://github.com/nathanielmanistaatgoogle","followers_url":"https://api.github.com/users/nathanielmanistaatgoogle/followers","following_url":"https://api.github.com/users/nathanielmanistaatgoogle/following{/other_user}","gists_url":"https://api.github.com/users/nathanielmanistaatgoogle/gists{/gist_id}","starred_url":"https://api.github.com/users/nathanielmanistaatgoogle/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nathanielmanistaatgoogle/subscriptions","organizations_url":"https://api.github.com/users/nathanielmanistaatgoogle/orgs","repos_url":"https://api.github.com/users/nathanielmanistaatgoogle/repos","events_url":"https://api.github.com/users/nathanielmanistaatgoogle/events{/privacy}","received_events_url":"https://api.github.com/users/nathanielmanistaatgoogle/received_events","type":"User","site_admin":false},"assignees":[{"login":"nathanielmanistaatgoogle","id":10131044,"avatar_url":"https://avatars.githubusercontent.com/u/10131044?v=3","gravatar_id":"","url":"https://api.github.com/users/nathanielmanistaatgoogle","html_url":"https://github.com/nathanielmanistaatgoogle","followers_url":"https://api.github.com/users/nathanielmanistaatgoogle/followers","following_url":"https://api.github.com/users/nathanielmanistaatgoogle/following{/other_user}","gists_url":"https://api.github.com/users/nathanielmanistaatgoogle/gists{/gist_id}","starred_url":"https://api.github.com/users/nathanielmanistaatgoogle/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nathanielmanistaatgoogle/subscriptions","organizations_url":"https://api.github.com/users/nathanielmanistaatgoogle/orgs","repos_url":"https://api.github.com/users/nathanielmanistaatgoogle/repos","events_url":"https://api.github.com/users/nathanielmanistaatgoogle/events{/privacy}","received_events_url":"https://api.github.com/users/nathanielmanistaatgoogle/received_events","type":"User","site_admin":false}],"milestone":{"url":"https://api.github.com/repos/grpc/grpc/milestones/45","html_url":"https://github.com/grpc/grpc/milestones/1.1","labels_url":"https://api.github.com/repos/grpc/grpc/milestones/45/labels","id":1845911,"number":45,"title":"1.1","description":"Soon after GA.","creator":{"login":"nathanielmanistaatgoogle","id":10131044,"avatar_url":"https://avatars.githubusercontent.com/u/10131044?v=3","gravatar_id":"","url":"https://api.github.com/users/nathanielmanistaatgoogle","html_url":"https://github.com/nathanielmanistaatgoogle","followers_url":"https://api.github.com/users/nathanielmanistaatgoogle/followers","following_url":"https://api.github.com/users/nathanielmanistaatgoogle/following{/other_user}","gists_url":"https://api.github.com/users/nathanielmanistaatgoogle/gists{/gist_id}","starred_url":"https://api.github.com/users/nathanielmanistaatgoogle/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nathanielmanistaatgoogle/subscriptions","organizations_url":"https://api.github.com/users/nathanielmanistaatgoogle/orgs","repos_url":"https://api.github.com/users/nathanielmanistaatgoogle/repos","events_url":"https://api.github.com/users/nathanielmanistaatgoogle/events{/privacy}","received_events_url":"https://api.github.com/users/nathanielmanistaatgoogle/received_events","type":"User","site_admin":false},"open_issues":27,"closed_issues":26,"state":"open","created_at":"2016-06-23T17:58:55Z","updated_at":"2016-10-21T02:23:48Z","due_on":null,"closed_at":null},"commits_url":"https://api.github.com/repos/grpc/grpc/pulls/8449/commits","review_comments_url":"https://api.github.com/repos/grpc/grpc/pulls/8449/comments","review_comment_url":"https://api.github.com/repos/grpc/grpc/pulls/comments{/number}","comments_url":"https://api.github.com/repos/grpc/grpc/issues/8449/comments","statuses_url":"https://api.github.com/repos/grpc/grpc/statuses/cbddcdf54ccb07403c309fa0bcf47cf85bcde71b","head":{"label":"ncteisen:new_python_interop_tests","ref":"new_python_interop_tests","sha":"cbddcdf54ccb07403c309fa0bcf47cf85bcde71b","user":{"login":"ncteisen","id":6148140,"avatar_url":"https://avatars.githubusercontent.com/u/6148140?v=3","gravatar_id":"","url":"https://api.github.com/users/ncteisen","html_url":"https://github.com/ncteisen","followers_url":"https://api.github.com/users/ncteisen/followers","following_url":"https://api.github.com/users/ncteisen/following{/other_user}","gists_url":"https://api.github.com/users/ncteisen/gists{/gist_id}","starred_url":"https://api.github.com/users/ncteisen/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ncteisen/subscriptions","organizations_url":"https://api.github.com/users/ncteisen/orgs","repos_url":"https://api.github.com/users/ncteisen/repos","events_url":"https://api.github.com/users/ncteisen/events{/privacy}","received_events_url":"https://api.github.com/users/ncteisen/received_events","type":"User","site_admin":false},"repo":{"id":69505172,"name":"grpc","full_name":"ncteisen/grpc","owner":{"login":"ncteisen","id":6148140,"avatar_url":"https://avatars.githubusercontent.com/u/6148140?v=3","gravatar_id":"","url":"https://api.github.com/users/ncteisen","html_url":"https://github.com/ncteisen","followers_url":"https://api.github.com/users/ncteisen/followers","following_url":"https://api.github.com/users/ncteisen/following{/other_user}","gists_url":"https://api.github.com/users/ncteisen/gists{/gist_id}","starred_url":"https://api.github.com/users/ncteisen/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ncteisen/subscriptions","organizations_url":"https://api.github.com/users/ncteisen/orgs","repos_url":"https://api.github.com/users/ncteisen/repos","events_url":"https://api.github.com/users/ncteisen/events{/privacy}","received_events_url":"https://api.github.com/users/ncteisen/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/ncteisen/grpc","description":"The C based gRPC (C++, Node.js, Python, Ruby, Objective-C, PHP, C#)","fork":true,"url":"https://api.github.com/repos/ncteisen/grpc","forks_url":"https://api.github.com/repos/ncteisen/grpc/forks","keys_url":"https://api.github.com/repos/ncteisen/grpc/keys{/key_id}","collaborators_url":"https://api.github.com/repos/ncteisen/grpc/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/ncteisen/grpc/teams","hooks_url":"https://api.github.com/repos/ncteisen/grpc/hooks","issue_events_url":"https://api.github.com/repos/ncteisen/grpc/issues/events{/number}","events_url":"https://api.github.com/repos/ncteisen/grpc/events","assignees_url":"https://api.github.com/repos/ncteisen/grpc/assignees{/user}","branches_url":"https://api.github.com/repos/ncteisen/grpc/branches{/branch}","tags_url":"https://api.github.com/repos/ncteisen/grpc/tags","blobs_url":"https://api.github.com/repos/ncteisen/grpc/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/ncteisen/grpc/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/ncteisen/grpc/git/refs{/sha}","trees_url":"https://api.github.com/repos/ncteisen/grpc/git/trees{/sha}","statuses_url":"https://api.github.com/repos/ncteisen/grpc/statuses/{sha}","languages_url":"https://api.github.com/repos/ncteisen/grpc/languages","stargazers_url":"https://api.github.com/repos/ncteisen/grpc/stargazers","contributors_url":"https://api.github.com/repos/ncteisen/grpc/contributors","subscribers_url":"https://api.github.com/repos/ncteisen/grpc/subscribers","subscription_url":"https://api.github.com/repos/ncteisen/grpc/subscription","commits_url":"https://api.github.com/repos/ncteisen/grpc/commits{/sha}","git_commits_url":"https://api.github.com/repos/ncteisen/grpc/git/commits{/sha}","comments_url":"https://api.github.com/repos/ncteisen/grpc/comments{/number}","issue_comment_url":"https://api.github.com/repos/ncteisen/grpc/issues/comments{/number}","contents_url":"https://api.github.com/repos/ncteisen/grpc/contents/{+path}","compare_url":"https://api.github.com/repos/ncteisen/grpc/compare/{base}...{head}","merges_url":"https://api.github.com/repos/ncteisen/grpc/merges","archive_url":"https://api.github.com/repos/ncteisen/grpc/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/ncteisen/grpc/downloads","issues_url":"https://api.github.com/repos/ncteisen/grpc/issues{/number}","pulls_url":"https://api.github.com/repos/ncteisen/grpc/pulls{/number}","milestones_url":"https://api.github.com/repos/ncteisen/grpc/milestones{/number}","notifications_url":"https://api.github.com/repos/ncteisen/grpc/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/ncteisen/grpc/labels{/name}","releases_url":"https://api.github.com/repos/ncteisen/grpc/releases{/id}","deployments_url":"https://api.github.com/repos/ncteisen/grpc/deployments","created_at":"2016-09-28T21:27:26Z","updated_at":"2016-09-28T21:27:36Z","pushed_at":"2016-10-25T19:12:11Z","git_url":"git://github.com/ncteisen/grpc.git","ssh_url":"git@github.com:ncteisen/grpc.git","clone_url":"https://github.com/ncteisen/grpc.git","svn_url":"https://github.com/ncteisen/grpc","homepage":"","size":88468,"stargazers_count":0,"watchers_count":0,"language":"C","has_issues":false,"has_downloads":false,"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":"grpc:master","ref":"master","sha":"b63d8d92437fac7f1a8ee5eb34767f8ff3852e3c","user":{"login":"grpc","id":7802525,"avatar_url":"https://avatars.githubusercontent.com/u/7802525?v=3","gravatar_id":"","url":"https://api.github.com/users/grpc","html_url":"https://github.com/grpc","followers_url":"https://api.github.com/users/grpc/followers","following_url":"https://api.github.com/users/grpc/following{/other_user}","gists_url":"https://api.github.com/users/grpc/gists{/gist_id}","starred_url":"https://api.github.com/users/grpc/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/grpc/subscriptions","organizations_url":"https://api.github.com/users/grpc/orgs","repos_url":"https://api.github.com/users/grpc/repos","events_url":"https://api.github.com/users/grpc/events{/privacy}","received_events_url":"https://api.github.com/users/grpc/received_events","type":"Organization","site_admin":false},"repo":{"id":27729880,"name":"grpc","full_name":"grpc/grpc","owner":{"login":"grpc","id":7802525,"avatar_url":"https://avatars.githubusercontent.com/u/7802525?v=3","gravatar_id":"","url":"https://api.github.com/users/grpc","html_url":"https://github.com/grpc","followers_url":"https://api.github.com/users/grpc/followers","following_url":"https://api.github.com/users/grpc/following{/other_user}","gists_url":"https://api.github.com/users/grpc/gists{/gist_id}","starred_url":"https://api.github.com/users/grpc/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/grpc/subscriptions","organizations_url":"https://api.github.com/users/grpc/orgs","repos_url":"https://api.github.com/users/grpc/repos","events_url":"https://api.github.com/users/grpc/events{/privacy}","received_events_url":"https://api.github.com/users/grpc/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/grpc/grpc","description":"The C based gRPC (C++, Node.js, Python, Ruby, Objective-C, PHP, C#)","fork":false,"url":"https://api.github.com/repos/grpc/grpc","forks_url":"https://api.github.com/repos/grpc/grpc/forks","keys_url":"https://api.github.com/repos/grpc/grpc/keys{/key_id}","collaborators_url":"https://api.github.com/repos/grpc/grpc/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/grpc/grpc/teams","hooks_url":"https://api.github.com/repos/grpc/grpc/hooks","issue_events_url":"https://api.github.com/repos/grpc/grpc/issues/events{/number}","events_url":"https://api.github.com/repos/grpc/grpc/events","assignees_url":"https://api.github.com/repos/grpc/grpc/assignees{/user}","branches_url":"https://api.github.com/repos/grpc/grpc/branches{/branch}","tags_url":"https://api.github.com/repos/grpc/grpc/tags","blobs_url":"https://api.github.com/repos/grpc/grpc/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/grpc/grpc/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/grpc/grpc/git/refs{/sha}","trees_url":"https://api.github.com/repos/grpc/grpc/git/trees{/sha}","statuses_url":"https://api.github.com/repos/grpc/grpc/statuses/{sha}","languages_url":"https://api.github.com/repos/grpc/grpc/languages","stargazers_url":"https://api.github.com/repos/grpc/grpc/stargazers","contributors_url":"https://api.github.com/repos/grpc/grpc/contributors","subscribers_url":"https://api.github.com/repos/grpc/grpc/subscribers","subscription_url":"https://api.github.com/repos/grpc/grpc/subscription","commits_url":"https://api.github.com/repos/grpc/grpc/commits{/sha}","git_commits_url":"https://api.github.com/repos/grpc/grpc/git/commits{/sha}","comments_url":"https://api.github.com/repos/grpc/grpc/comments{/number}","issue_comment_url":"https://api.github.com/repos/grpc/grpc/issues/comments{/number}","contents_url":"https://api.github.com/repos/grpc/grpc/contents/{+path}","compare_url":"https://api.github.com/repos/grpc/grpc/compare/{base}...{head}","merges_url":"https://api.github.com/repos/grpc/grpc/merges","archive_url":"https://api.github.com/repos/grpc/grpc/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/grpc/grpc/downloads","issues_url":"https://api.github.com/repos/grpc/grpc/issues{/number}","pulls_url":"https://api.github.com/repos/grpc/grpc/pulls{/number}","milestones_url":"https://api.github.com/repos/grpc/grpc/milestones{/number}","notifications_url":"https://api.github.com/repos/grpc/grpc/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/grpc/grpc/labels{/name}","releases_url":"https://api.github.com/repos/grpc/grpc/releases{/id}","deployments_url":"https://api.github.com/repos/grpc/grpc/deployments","created_at":"2014-12-08T18:58:53Z","updated_at":"2016-10-25T16:37:44Z","pushed_at":"2016-10-25T19:26:32Z","git_url":"git://github.com/grpc/grpc.git","ssh_url":"git@github.com:grpc/grpc.git","clone_url":"https://github.com/grpc/grpc.git","svn_url":"https://github.com/grpc/grpc","homepage":"","size":218050,"stargazers_count":7542,"watchers_count":7542,"language":"C","has_issues":true,"has_downloads":false,"has_wiki":true,"has_pages":true,"forks_count":1441,"mirror_url":null,"open_issues_count":851,"forks":1441,"open_issues":851,"watchers":7542,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/grpc/grpc/pulls/8449"},"html":{"href":"https://github.com/grpc/grpc/pull/8449"},"issue":{"href":"https://api.github.com/repos/grpc/grpc/issues/8449"},"comments":{"href":"https://api.github.com/repos/grpc/grpc/issues/8449/comments"},"review_comments":{"href":"https://api.github.com/repos/grpc/grpc/pulls/8449/comments"},"review_comment":{"href":"https://api.github.com/repos/grpc/grpc/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/grpc/grpc/pulls/8449/commits"},"statuses":{"href":"https://api.github.com/repos/grpc/grpc/statuses/cbddcdf54ccb07403c309fa0bcf47cf85bcde71b"}}}}
{"actor":{"display_login":"nathanielmanistaatgoogle"}}