{"action":"created","comment":{"url":"https://api.github.com/repos/Jakealope/network_tools/pulls/comments/24645793","id":24645793,"diff_hunk":"@@ -0,0 +1,27 @@\n+import socket\n+import sys\n+\n+\n+def clientmessage(msg):\n+\n+    client_socket = socket.socket(\n+        socket.AF_INET,\n+        socket.SOCK_STREAM,\n+        socket.IPPROTO_IP)\n+    client_socket.connect(('127.0.0.1', 50000))\n+    client_socket.sendall(msg)\n+    client_socket.shutdown(socket.SHUT_WR)\n+    buffsize = 32\n+    response = ''\n+    done = False\n+    while not done:\n+        msg_part = client_socket.recv(buffsize)\n+        if len(msg_part) < buffsize:\n+            done = True\n+            client_socket.close()\n+        response += msg_part\n+    return response\n+\n+\n+if __name__ == '__main__':\n+    clientmessage(sys.argv[1])","path":"echo_client.py","position":27,"original_position":27,"commit_id":"fb8404dcb4b7ba8d3da6e470a4e143cb80c9fb4c","original_commit_id":"fb8404dcb4b7ba8d3da6e470a4e143cb80c9fb4c","user":{"login":"cewing","id":417109,"avatar_url":"https://avatars.githubusercontent.com/u/417109?v=3","gravatar_id":"","url":"https://api.github.com/users/cewing","html_url":"https://github.com/cewing","followers_url":"https://api.github.com/users/cewing/followers","following_url":"https://api.github.com/users/cewing/following{/other_user}","gists_url":"https://api.github.com/users/cewing/gists{/gist_id}","starred_url":"https://api.github.com/users/cewing/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/cewing/subscriptions","organizations_url":"https://api.github.com/users/cewing/orgs","repos_url":"https://api.github.com/users/cewing/repos","events_url":"https://api.github.com/users/cewing/events{/privacy}","received_events_url":"https://api.github.com/users/cewing/received_events","type":"User","site_admin":false},"body":"I think it'd be nice to bind the return of this call to a value, and then print it out so the user can tell that the echo worked properly.  \r\n\r\nOther than that, this is fine work.","created_at":"2015-02-13T05:56:15Z","updated_at":"2015-02-13T05:56:15Z","html_url":"https://github.com/Jakealope/network_tools/pull/1#discussion_r24645793","pull_request_url":"https://api.github.com/repos/Jakealope/network_tools/pulls/1","_links":{"self":{"href":"https://api.github.com/repos/Jakealope/network_tools/pulls/comments/24645793"},"html":{"href":"https://github.com/Jakealope/network_tools/pull/1#discussion_r24645793"},"pull_request":{"href":"https://api.github.com/repos/Jakealope/network_tools/pulls/1"}}},"pull_request":{"url":"https://api.github.com/repos/Jakealope/network_tools/pulls/1","id":29064578,"html_url":"https://github.com/Jakealope/network_tools/pull/1","diff_url":"https://github.com/Jakealope/network_tools/pull/1.diff","patch_url":"https://github.com/Jakealope/network_tools/pull/1.patch","issue_url":"https://api.github.com/repos/Jakealope/network_tools/issues/1","number":1,"state":"open","locked":false,"title":"Echo","user":{"login":"Jakealope","id":4807654,"avatar_url":"https://avatars.githubusercontent.com/u/4807654?v=3","gravatar_id":"","url":"https://api.github.com/users/Jakealope","html_url":"https://github.com/Jakealope","followers_url":"https://api.github.com/users/Jakealope/followers","following_url":"https://api.github.com/users/Jakealope/following{/other_user}","gists_url":"https://api.github.com/users/Jakealope/gists{/gist_id}","starred_url":"https://api.github.com/users/Jakealope/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Jakealope/subscriptions","organizations_url":"https://api.github.com/users/Jakealope/orgs","repos_url":"https://api.github.com/users/Jakealope/repos","events_url":"https://api.github.com/users/Jakealope/events{/privacy}","received_events_url":"https://api.github.com/users/Jakealope/received_events","type":"User","site_admin":false},"body":"added tests and completed server and client code","created_at":"2015-02-11T02:39:46Z","updated_at":"2015-02-13T05:56:15Z","closed_at":null,"merged_at":null,"merge_commit_sha":"d6f230c78c43f1c14409301d5a5933d364cdbb9a","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/Jakealope/network_tools/pulls/1/commits","review_comments_url":"https://api.github.com/repos/Jakealope/network_tools/pulls/1/comments","review_comment_url":"https://api.github.com/repos/Jakealope/network_tools/pulls/comments/{number}","comments_url":"https://api.github.com/repos/Jakealope/network_tools/issues/1/comments","statuses_url":"https://api.github.com/repos/Jakealope/network_tools/statuses/fb8404dcb4b7ba8d3da6e470a4e143cb80c9fb4c","head":{"label":"Jakealope:echo","ref":"echo","sha":"fb8404dcb4b7ba8d3da6e470a4e143cb80c9fb4c","user":{"login":"Jakealope","id":4807654,"avatar_url":"https://avatars.githubusercontent.com/u/4807654?v=3","gravatar_id":"","url":"https://api.github.com/users/Jakealope","html_url":"https://github.com/Jakealope","followers_url":"https://api.github.com/users/Jakealope/followers","following_url":"https://api.github.com/users/Jakealope/following{/other_user}","gists_url":"https://api.github.com/users/Jakealope/gists{/gist_id}","starred_url":"https://api.github.com/users/Jakealope/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Jakealope/subscriptions","organizations_url":"https://api.github.com/users/Jakealope/orgs","repos_url":"https://api.github.com/users/Jakealope/repos","events_url":"https://api.github.com/users/Jakealope/events{/privacy}","received_events_url":"https://api.github.com/users/Jakealope/received_events","type":"User","site_admin":false},"repo":{"id":30613235,"name":"network_tools","full_name":"Jakealope/network_tools","owner":{"login":"Jakealope","id":4807654,"avatar_url":"https://avatars.githubusercontent.com/u/4807654?v=3","gravatar_id":"","url":"https://api.github.com/users/Jakealope","html_url":"https://github.com/Jakealope","followers_url":"https://api.github.com/users/Jakealope/followers","following_url":"https://api.github.com/users/Jakealope/following{/other_user}","gists_url":"https://api.github.com/users/Jakealope/gists{/gist_id}","starred_url":"https://api.github.com/users/Jakealope/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Jakealope/subscriptions","organizations_url":"https://api.github.com/users/Jakealope/orgs","repos_url":"https://api.github.com/users/Jakealope/repos","events_url":"https://api.github.com/users/Jakealope/events{/privacy}","received_events_url":"https://api.github.com/users/Jakealope/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/Jakealope/network_tools","description":"","fork":false,"url":"https://api.github.com/repos/Jakealope/network_tools","forks_url":"https://api.github.com/repos/Jakealope/network_tools/forks","keys_url":"https://api.github.com/repos/Jakealope/network_tools/keys{/key_id}","collaborators_url":"https://api.github.com/repos/Jakealope/network_tools/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/Jakealope/network_tools/teams","hooks_url":"https://api.github.com/repos/Jakealope/network_tools/hooks","issue_events_url":"https://api.github.com/repos/Jakealope/network_tools/issues/events{/number}","events_url":"https://api.github.com/repos/Jakealope/network_tools/events","assignees_url":"https://api.github.com/repos/Jakealope/network_tools/assignees{/user}","branches_url":"https://api.github.com/repos/Jakealope/network_tools/branches{/branch}","tags_url":"https://api.github.com/repos/Jakealope/network_tools/tags","blobs_url":"https://api.github.com/repos/Jakealope/network_tools/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/Jakealope/network_tools/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/Jakealope/network_tools/git/refs{/sha}","trees_url":"https://api.github.com/repos/Jakealope/network_tools/git/trees{/sha}","statuses_url":"https://api.github.com/repos/Jakealope/network_tools/statuses/{sha}","languages_url":"https://api.github.com/repos/Jakealope/network_tools/languages","stargazers_url":"https://api.github.com/repos/Jakealope/network_tools/stargazers","contributors_url":"https://api.github.com/repos/Jakealope/network_tools/contributors","subscribers_url":"https://api.github.com/repos/Jakealope/network_tools/subscribers","subscription_url":"https://api.github.com/repos/Jakealope/network_tools/subscription","commits_url":"https://api.github.com/repos/Jakealope/network_tools/commits{/sha}","git_commits_url":"https://api.github.com/repos/Jakealope/network_tools/git/commits{/sha}","comments_url":"https://api.github.com/repos/Jakealope/network_tools/comments{/number}","issue_comment_url":"https://api.github.com/repos/Jakealope/network_tools/issues/comments/{number}","contents_url":"https://api.github.com/repos/Jakealope/network_tools/contents/{+path}","compare_url":"https://api.github.com/repos/Jakealope/network_tools/compare/{base}...{head}","merges_url":"https://api.github.com/repos/Jakealope/network_tools/merges","archive_url":"https://api.github.com/repos/Jakealope/network_tools/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/Jakealope/network_tools/downloads","issues_url":"https://api.github.com/repos/Jakealope/network_tools/issues{/number}","pulls_url":"https://api.github.com/repos/Jakealope/network_tools/pulls{/number}","milestones_url":"https://api.github.com/repos/Jakealope/network_tools/milestones{/number}","notifications_url":"https://api.github.com/repos/Jakealope/network_tools/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/Jakealope/network_tools/labels{/name}","releases_url":"https://api.github.com/repos/Jakealope/network_tools/releases{/id}","created_at":"2015-02-10T20:33:13Z","updated_at":"2015-02-10T20:33:13Z","pushed_at":"2015-02-12T02:42:46Z","git_url":"git://github.com/Jakealope/network_tools.git","ssh_url":"git@github.com:Jakealope/network_tools.git","clone_url":"https://github.com/Jakealope/network_tools.git","svn_url":"https://github.com/Jakealope/network_tools","homepage":null,"size":0,"stargazers_count":0,"watchers_count":0,"language":null,"has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":1,"forks":0,"open_issues":1,"watchers":0,"default_branch":"master"}},"base":{"label":"Jakealope:master","ref":"master","sha":"be0ee660ec3b5065fcf2f44665eda96486b79f85","user":{"login":"Jakealope","id":4807654,"avatar_url":"https://avatars.githubusercontent.com/u/4807654?v=3","gravatar_id":"","url":"https://api.github.com/users/Jakealope","html_url":"https://github.com/Jakealope","followers_url":"https://api.github.com/users/Jakealope/followers","following_url":"https://api.github.com/users/Jakealope/following{/other_user}","gists_url":"https://api.github.com/users/Jakealope/gists{/gist_id}","starred_url":"https://api.github.com/users/Jakealope/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Jakealope/subscriptions","organizations_url":"https://api.github.com/users/Jakealope/orgs","repos_url":"https://api.github.com/users/Jakealope/repos","events_url":"https://api.github.com/users/Jakealope/events{/privacy}","received_events_url":"https://api.github.com/users/Jakealope/received_events","type":"User","site_admin":false},"repo":{"id":30613235,"name":"network_tools","full_name":"Jakealope/network_tools","owner":{"login":"Jakealope","id":4807654,"avatar_url":"https://avatars.githubusercontent.com/u/4807654?v=3","gravatar_id":"","url":"https://api.github.com/users/Jakealope","html_url":"https://github.com/Jakealope","followers_url":"https://api.github.com/users/Jakealope/followers","following_url":"https://api.github.com/users/Jakealope/following{/other_user}","gists_url":"https://api.github.com/users/Jakealope/gists{/gist_id}","starred_url":"https://api.github.com/users/Jakealope/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Jakealope/subscriptions","organizations_url":"https://api.github.com/users/Jakealope/orgs","repos_url":"https://api.github.com/users/Jakealope/repos","events_url":"https://api.github.com/users/Jakealope/events{/privacy}","received_events_url":"https://api.github.com/users/Jakealope/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/Jakealope/network_tools","description":"","fork":false,"url":"https://api.github.com/repos/Jakealope/network_tools","forks_url":"https://api.github.com/repos/Jakealope/network_tools/forks","keys_url":"https://api.github.com/repos/Jakealope/network_tools/keys{/key_id}","collaborators_url":"https://api.github.com/repos/Jakealope/network_tools/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/Jakealope/network_tools/teams","hooks_url":"https://api.github.com/repos/Jakealope/network_tools/hooks","issue_events_url":"https://api.github.com/repos/Jakealope/network_tools/issues/events{/number}","events_url":"https://api.github.com/repos/Jakealope/network_tools/events","assignees_url":"https://api.github.com/repos/Jakealope/network_tools/assignees{/user}","branches_url":"https://api.github.com/repos/Jakealope/network_tools/branches{/branch}","tags_url":"https://api.github.com/repos/Jakealope/network_tools/tags","blobs_url":"https://api.github.com/repos/Jakealope/network_tools/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/Jakealope/network_tools/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/Jakealope/network_tools/git/refs{/sha}","trees_url":"https://api.github.com/repos/Jakealope/network_tools/git/trees{/sha}","statuses_url":"https://api.github.com/repos/Jakealope/network_tools/statuses/{sha}","languages_url":"https://api.github.com/repos/Jakealope/network_tools/languages","stargazers_url":"https://api.github.com/repos/Jakealope/network_tools/stargazers","contributors_url":"https://api.github.com/repos/Jakealope/network_tools/contributors","subscribers_url":"https://api.github.com/repos/Jakealope/network_tools/subscribers","subscription_url":"https://api.github.com/repos/Jakealope/network_tools/subscription","commits_url":"https://api.github.com/repos/Jakealope/network_tools/commits{/sha}","git_commits_url":"https://api.github.com/repos/Jakealope/network_tools/git/commits{/sha}","comments_url":"https://api.github.com/repos/Jakealope/network_tools/comments{/number}","issue_comment_url":"https://api.github.com/repos/Jakealope/network_tools/issues/comments/{number}","contents_url":"https://api.github.com/repos/Jakealope/network_tools/contents/{+path}","compare_url":"https://api.github.com/repos/Jakealope/network_tools/compare/{base}...{head}","merges_url":"https://api.github.com/repos/Jakealope/network_tools/merges","archive_url":"https://api.github.com/repos/Jakealope/network_tools/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/Jakealope/network_tools/downloads","issues_url":"https://api.github.com/repos/Jakealope/network_tools/issues{/number}","pulls_url":"https://api.github.com/repos/Jakealope/network_tools/pulls{/number}","milestones_url":"https://api.github.com/repos/Jakealope/network_tools/milestones{/number}","notifications_url":"https://api.github.com/repos/Jakealope/network_tools/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/Jakealope/network_tools/labels{/name}","releases_url":"https://api.github.com/repos/Jakealope/network_tools/releases{/id}","created_at":"2015-02-10T20:33:13Z","updated_at":"2015-02-10T20:33:13Z","pushed_at":"2015-02-12T02:42:46Z","git_url":"git://github.com/Jakealope/network_tools.git","ssh_url":"git@github.com:Jakealope/network_tools.git","clone_url":"https://github.com/Jakealope/network_tools.git","svn_url":"https://github.com/Jakealope/network_tools","homepage":null,"size":0,"stargazers_count":0,"watchers_count":0,"language":null,"has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":1,"forks":0,"open_issues":1,"watchers":0,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/Jakealope/network_tools/pulls/1"},"html":{"href":"https://github.com/Jakealope/network_tools/pull/1"},"issue":{"href":"https://api.github.com/repos/Jakealope/network_tools/issues/1"},"comments":{"href":"https://api.github.com/repos/Jakealope/network_tools/issues/1/comments"},"review_comments":{"href":"https://api.github.com/repos/Jakealope/network_tools/pulls/1/comments"},"review_comment":{"href":"https://api.github.com/repos/Jakealope/network_tools/pulls/comments/{number}"},"commits":{"href":"https://api.github.com/repos/Jakealope/network_tools/pulls/1/commits"},"statuses":{"href":"https://api.github.com/repos/Jakealope/network_tools/statuses/fb8404dcb4b7ba8d3da6e470a4e143cb80c9fb4c"}}}}