{"action":"created","comment":{"url":"https://api.github.com/repos/project-rig/rig/pulls/comments/45333423","id":45333423,"diff_hunk":"@@ -174,7 +186,20 @@ def send_scp(self, *args, **kwargs):\n \n     def _get_connection(self, x, y):\n         \"\"\"Get the appropriate connection for a chip.\"\"\"\n-        return self.connections[0]\n+        if self._width is None or self._height is None:\n+            return self.connections[None]\n+        else:\n+            # If possible, use the local Ethernet connected chip\n+            eth_chip = spinn5_local_eth_coord(x, y, self._width, self._height)\n+            conn = self.connections.get(eth_chip)\n+            if conn is not None:\n+                return conn\n+            else:\n+                # If no connection was available to the local board, chose\n+                # another arbitrarily.\n+                # XXX: This choice will cause lots of contention in systems\n+                # with many missing Ethernet connections.","path":"rig/machine_control/machine_controller.py","position":64,"original_position":64,"commit_id":"b47d7b83362a6ebda5f220672593be797aeeaf8c","original_commit_id":"b47d7b83362a6ebda5f220672593be797aeeaf8c","user":{"login":"mundya","id":3439837,"avatar_url":"https://avatars.githubusercontent.com/u/3439837?v=3","gravatar_id":"","url":"https://api.github.com/users/mundya","html_url":"https://github.com/mundya","followers_url":"https://api.github.com/users/mundya/followers","following_url":"https://api.github.com/users/mundya/following{/other_user}","gists_url":"https://api.github.com/users/mundya/gists{/gist_id}","starred_url":"https://api.github.com/users/mundya/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mundya/subscriptions","organizations_url":"https://api.github.com/users/mundya/orgs","repos_url":"https://api.github.com/users/mundya/repos","events_url":"https://api.github.com/users/mundya/events{/privacy}","received_events_url":"https://api.github.com/users/mundya/received_events","type":"User","site_admin":false},"body":"~~It wouldn't be too hard to construct something that picked ...~~","created_at":"2015-11-19T12:19:48Z","updated_at":"2015-11-19T12:19:48Z","html_url":"https://github.com/project-rig/rig/pull/201#discussion_r45333423","pull_request_url":"https://api.github.com/repos/project-rig/rig/pulls/201","_links":{"self":{"href":"https://api.github.com/repos/project-rig/rig/pulls/comments/45333423"},"html":{"href":"https://github.com/project-rig/rig/pull/201#discussion_r45333423"},"pull_request":{"href":"https://api.github.com/repos/project-rig/rig/pulls/201"}}},"pull_request":{"url":"https://api.github.com/repos/project-rig/rig/pulls/201","id":50745301,"html_url":"https://github.com/project-rig/rig/pull/201","diff_url":"https://github.com/project-rig/rig/pull/201.diff","patch_url":"https://github.com/project-rig/rig/pull/201.patch","issue_url":"https://api.github.com/repos/project-rig/rig/issues/201","number":201,"state":"open","locked":false,"title":"Discover and use multiple Ethernet connections","user":{"login":"mossblaser","id":193514,"avatar_url":"https://avatars.githubusercontent.com/u/193514?v=3","gravatar_id":"","url":"https://api.github.com/users/mossblaser","html_url":"https://github.com/mossblaser","followers_url":"https://api.github.com/users/mossblaser/followers","following_url":"https://api.github.com/users/mossblaser/following{/other_user}","gists_url":"https://api.github.com/users/mossblaser/gists{/gist_id}","starred_url":"https://api.github.com/users/mossblaser/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mossblaser/subscriptions","organizations_url":"https://api.github.com/users/mossblaser/orgs","repos_url":"https://api.github.com/users/mossblaser/repos","events_url":"https://api.github.com/users/mossblaser/events{/privacy}","received_events_url":"https://api.github.com/users/mossblaser/received_events","type":"User","site_admin":false},"body":"This commit adds support for discovering and using multiple Ethernet\r\nconnections (when available) but does not feature any way to use these\r\nconnections in parallel to improve performance. A limited performance\r\nimprovement due to reduced average latency within the machine may be possible.\r\nThis feature may also allow more robust communication with machines whose links\r\nhave died during runtime.\r\n\r\nThis commit was cherry-picked from commit 08ff6e1 (part of the\r\nhigh-throughput-io branch) since its functionality is useful and doesn't\r\ninvolve any API changes.\r\n\r\nPerhaps some mechanism for triggering this discovery automatically would be worthwhile since there is very little reason to *not* want this functionality(?)","created_at":"2015-11-15T12:08:45Z","updated_at":"2015-11-19T12:19:48Z","closed_at":null,"merged_at":null,"merge_commit_sha":"cb063e964e517d1f5b3ad3b7999fff0733d654ef","assignee":{"login":"mundya","id":3439837,"avatar_url":"https://avatars.githubusercontent.com/u/3439837?v=3","gravatar_id":"","url":"https://api.github.com/users/mundya","html_url":"https://github.com/mundya","followers_url":"https://api.github.com/users/mundya/followers","following_url":"https://api.github.com/users/mundya/following{/other_user}","gists_url":"https://api.github.com/users/mundya/gists{/gist_id}","starred_url":"https://api.github.com/users/mundya/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mundya/subscriptions","organizations_url":"https://api.github.com/users/mundya/orgs","repos_url":"https://api.github.com/users/mundya/repos","events_url":"https://api.github.com/users/mundya/events{/privacy}","received_events_url":"https://api.github.com/users/mundya/received_events","type":"User","site_admin":false},"milestone":{"url":"https://api.github.com/repos/project-rig/rig/milestones/1","html_url":"https://github.com/project-rig/rig/milestones/1.0","labels_url":"https://api.github.com/repos/project-rig/rig/milestones/1/labels","id":945495,"number":1,"title":"1.0","description":"A working release for use with Nengo/SpiNNaker.","creator":{"login":"mundya","id":3439837,"avatar_url":"https://avatars.githubusercontent.com/u/3439837?v=3","gravatar_id":"","url":"https://api.github.com/users/mundya","html_url":"https://github.com/mundya","followers_url":"https://api.github.com/users/mundya/followers","following_url":"https://api.github.com/users/mundya/following{/other_user}","gists_url":"https://api.github.com/users/mundya/gists{/gist_id}","starred_url":"https://api.github.com/users/mundya/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mundya/subscriptions","organizations_url":"https://api.github.com/users/mundya/orgs","repos_url":"https://api.github.com/users/mundya/repos","events_url":"https://api.github.com/users/mundya/events{/privacy}","received_events_url":"https://api.github.com/users/mundya/received_events","type":"User","site_admin":false},"open_issues":11,"closed_issues":110,"state":"open","created_at":"2015-01-21T16:25:41Z","updated_at":"2015-11-17T11:41:45Z","due_on":null,"closed_at":null},"commits_url":"https://api.github.com/repos/project-rig/rig/pulls/201/commits","review_comments_url":"https://api.github.com/repos/project-rig/rig/pulls/201/comments","review_comment_url":"https://api.github.com/repos/project-rig/rig/pulls/comments{/number}","comments_url":"https://api.github.com/repos/project-rig/rig/issues/201/comments","statuses_url":"https://api.github.com/repos/project-rig/rig/statuses/b47d7b83362a6ebda5f220672593be797aeeaf8c","head":{"label":"project-rig:multiple-ethernet","ref":"multiple-ethernet","sha":"b47d7b83362a6ebda5f220672593be797aeeaf8c","user":{"login":"project-rig","id":11227885,"avatar_url":"https://avatars.githubusercontent.com/u/11227885?v=3","gravatar_id":"","url":"https://api.github.com/users/project-rig","html_url":"https://github.com/project-rig","followers_url":"https://api.github.com/users/project-rig/followers","following_url":"https://api.github.com/users/project-rig/following{/other_user}","gists_url":"https://api.github.com/users/project-rig/gists{/gist_id}","starred_url":"https://api.github.com/users/project-rig/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/project-rig/subscriptions","organizations_url":"https://api.github.com/users/project-rig/orgs","repos_url":"https://api.github.com/users/project-rig/repos","events_url":"https://api.github.com/users/project-rig/events{/privacy}","received_events_url":"https://api.github.com/users/project-rig/received_events","type":"Organization","site_admin":false},"repo":{"id":29497314,"name":"rig","full_name":"project-rig/rig","owner":{"login":"project-rig","id":11227885,"avatar_url":"https://avatars.githubusercontent.com/u/11227885?v=3","gravatar_id":"","url":"https://api.github.com/users/project-rig","html_url":"https://github.com/project-rig","followers_url":"https://api.github.com/users/project-rig/followers","following_url":"https://api.github.com/users/project-rig/following{/other_user}","gists_url":"https://api.github.com/users/project-rig/gists{/gist_id}","starred_url":"https://api.github.com/users/project-rig/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/project-rig/subscriptions","organizations_url":"https://api.github.com/users/project-rig/orgs","repos_url":"https://api.github.com/users/project-rig/repos","events_url":"https://api.github.com/users/project-rig/events{/privacy}","received_events_url":"https://api.github.com/users/project-rig/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/project-rig/rig","description":"A collection of tools for developing SpiNNaker applications.","fork":false,"url":"https://api.github.com/repos/project-rig/rig","forks_url":"https://api.github.com/repos/project-rig/rig/forks","keys_url":"https://api.github.com/repos/project-rig/rig/keys{/key_id}","collaborators_url":"https://api.github.com/repos/project-rig/rig/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/project-rig/rig/teams","hooks_url":"https://api.github.com/repos/project-rig/rig/hooks","issue_events_url":"https://api.github.com/repos/project-rig/rig/issues/events{/number}","events_url":"https://api.github.com/repos/project-rig/rig/events","assignees_url":"https://api.github.com/repos/project-rig/rig/assignees{/user}","branches_url":"https://api.github.com/repos/project-rig/rig/branches{/branch}","tags_url":"https://api.github.com/repos/project-rig/rig/tags","blobs_url":"https://api.github.com/repos/project-rig/rig/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/project-rig/rig/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/project-rig/rig/git/refs{/sha}","trees_url":"https://api.github.com/repos/project-rig/rig/git/trees{/sha}","statuses_url":"https://api.github.com/repos/project-rig/rig/statuses/{sha}","languages_url":"https://api.github.com/repos/project-rig/rig/languages","stargazers_url":"https://api.github.com/repos/project-rig/rig/stargazers","contributors_url":"https://api.github.com/repos/project-rig/rig/contributors","subscribers_url":"https://api.github.com/repos/project-rig/rig/subscribers","subscription_url":"https://api.github.com/repos/project-rig/rig/subscription","commits_url":"https://api.github.com/repos/project-rig/rig/commits{/sha}","git_commits_url":"https://api.github.com/repos/project-rig/rig/git/commits{/sha}","comments_url":"https://api.github.com/repos/project-rig/rig/comments{/number}","issue_comment_url":"https://api.github.com/repos/project-rig/rig/issues/comments{/number}","contents_url":"https://api.github.com/repos/project-rig/rig/contents/{+path}","compare_url":"https://api.github.com/repos/project-rig/rig/compare/{base}...{head}","merges_url":"https://api.github.com/repos/project-rig/rig/merges","archive_url":"https://api.github.com/repos/project-rig/rig/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/project-rig/rig/downloads","issues_url":"https://api.github.com/repos/project-rig/rig/issues{/number}","pulls_url":"https://api.github.com/repos/project-rig/rig/pulls{/number}","milestones_url":"https://api.github.com/repos/project-rig/rig/milestones{/number}","notifications_url":"https://api.github.com/repos/project-rig/rig/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/project-rig/rig/labels{/name}","releases_url":"https://api.github.com/repos/project-rig/rig/releases{/id}","created_at":"2015-01-19T21:20:40Z","updated_at":"2015-05-03T15:04:13Z","pushed_at":"2015-11-17T11:41:46Z","git_url":"git://github.com/project-rig/rig.git","ssh_url":"git@github.com:project-rig/rig.git","clone_url":"https://github.com/project-rig/rig.git","svn_url":"https://github.com/project-rig/rig","homepage":"","size":1744,"stargazers_count":0,"watchers_count":0,"language":"Python","has_issues":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":1,"mirror_url":null,"open_issues_count":15,"forks":1,"open_issues":15,"watchers":0,"default_branch":"master"}},"base":{"label":"project-rig:master","ref":"master","sha":"b10e31e35da630420d3fd23afcc494a12656c8af","user":{"login":"project-rig","id":11227885,"avatar_url":"https://avatars.githubusercontent.com/u/11227885?v=3","gravatar_id":"","url":"https://api.github.com/users/project-rig","html_url":"https://github.com/project-rig","followers_url":"https://api.github.com/users/project-rig/followers","following_url":"https://api.github.com/users/project-rig/following{/other_user}","gists_url":"https://api.github.com/users/project-rig/gists{/gist_id}","starred_url":"https://api.github.com/users/project-rig/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/project-rig/subscriptions","organizations_url":"https://api.github.com/users/project-rig/orgs","repos_url":"https://api.github.com/users/project-rig/repos","events_url":"https://api.github.com/users/project-rig/events{/privacy}","received_events_url":"https://api.github.com/users/project-rig/received_events","type":"Organization","site_admin":false},"repo":{"id":29497314,"name":"rig","full_name":"project-rig/rig","owner":{"login":"project-rig","id":11227885,"avatar_url":"https://avatars.githubusercontent.com/u/11227885?v=3","gravatar_id":"","url":"https://api.github.com/users/project-rig","html_url":"https://github.com/project-rig","followers_url":"https://api.github.com/users/project-rig/followers","following_url":"https://api.github.com/users/project-rig/following{/other_user}","gists_url":"https://api.github.com/users/project-rig/gists{/gist_id}","starred_url":"https://api.github.com/users/project-rig/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/project-rig/subscriptions","organizations_url":"https://api.github.com/users/project-rig/orgs","repos_url":"https://api.github.com/users/project-rig/repos","events_url":"https://api.github.com/users/project-rig/events{/privacy}","received_events_url":"https://api.github.com/users/project-rig/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/project-rig/rig","description":"A collection of tools for developing SpiNNaker applications.","fork":false,"url":"https://api.github.com/repos/project-rig/rig","forks_url":"https://api.github.com/repos/project-rig/rig/forks","keys_url":"https://api.github.com/repos/project-rig/rig/keys{/key_id}","collaborators_url":"https://api.github.com/repos/project-rig/rig/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/project-rig/rig/teams","hooks_url":"https://api.github.com/repos/project-rig/rig/hooks","issue_events_url":"https://api.github.com/repos/project-rig/rig/issues/events{/number}","events_url":"https://api.github.com/repos/project-rig/rig/events","assignees_url":"https://api.github.com/repos/project-rig/rig/assignees{/user}","branches_url":"https://api.github.com/repos/project-rig/rig/branches{/branch}","tags_url":"https://api.github.com/repos/project-rig/rig/tags","blobs_url":"https://api.github.com/repos/project-rig/rig/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/project-rig/rig/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/project-rig/rig/git/refs{/sha}","trees_url":"https://api.github.com/repos/project-rig/rig/git/trees{/sha}","statuses_url":"https://api.github.com/repos/project-rig/rig/statuses/{sha}","languages_url":"https://api.github.com/repos/project-rig/rig/languages","stargazers_url":"https://api.github.com/repos/project-rig/rig/stargazers","contributors_url":"https://api.github.com/repos/project-rig/rig/contributors","subscribers_url":"https://api.github.com/repos/project-rig/rig/subscribers","subscription_url":"https://api.github.com/repos/project-rig/rig/subscription","commits_url":"https://api.github.com/repos/project-rig/rig/commits{/sha}","git_commits_url":"https://api.github.com/repos/project-rig/rig/git/commits{/sha}","comments_url":"https://api.github.com/repos/project-rig/rig/comments{/number}","issue_comment_url":"https://api.github.com/repos/project-rig/rig/issues/comments{/number}","contents_url":"https://api.github.com/repos/project-rig/rig/contents/{+path}","compare_url":"https://api.github.com/repos/project-rig/rig/compare/{base}...{head}","merges_url":"https://api.github.com/repos/project-rig/rig/merges","archive_url":"https://api.github.com/repos/project-rig/rig/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/project-rig/rig/downloads","issues_url":"https://api.github.com/repos/project-rig/rig/issues{/number}","pulls_url":"https://api.github.com/repos/project-rig/rig/pulls{/number}","milestones_url":"https://api.github.com/repos/project-rig/rig/milestones{/number}","notifications_url":"https://api.github.com/repos/project-rig/rig/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/project-rig/rig/labels{/name}","releases_url":"https://api.github.com/repos/project-rig/rig/releases{/id}","created_at":"2015-01-19T21:20:40Z","updated_at":"2015-05-03T15:04:13Z","pushed_at":"2015-11-17T11:41:46Z","git_url":"git://github.com/project-rig/rig.git","ssh_url":"git@github.com:project-rig/rig.git","clone_url":"https://github.com/project-rig/rig.git","svn_url":"https://github.com/project-rig/rig","homepage":"","size":1744,"stargazers_count":0,"watchers_count":0,"language":"Python","has_issues":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":1,"mirror_url":null,"open_issues_count":15,"forks":1,"open_issues":15,"watchers":0,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/project-rig/rig/pulls/201"},"html":{"href":"https://github.com/project-rig/rig/pull/201"},"issue":{"href":"https://api.github.com/repos/project-rig/rig/issues/201"},"comments":{"href":"https://api.github.com/repos/project-rig/rig/issues/201/comments"},"review_comments":{"href":"https://api.github.com/repos/project-rig/rig/pulls/201/comments"},"review_comment":{"href":"https://api.github.com/repos/project-rig/rig/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/project-rig/rig/pulls/201/commits"},"statuses":{"href":"https://api.github.com/repos/project-rig/rig/statuses/b47d7b83362a6ebda5f220672593be797aeeaf8c"}}}}