{"action":"created","comment":{"url":"https://api.github.com/repos/saltyrtc/saltyrtc-server-python/pulls/comments/184397718","pull_request_review_id":115585100,"id":184397718,"diff_hunk":"@@ -231,6 +232,34 @@ def handler(self, connection, ws_path):\n         # Remove client from path\n         path.remove_client(client)\n \n+        # Send disconnected message if client was authenticated\n+        if client.authenticated:\n+            # Initiator: Send to all responders\n+            if client.type == AddressType.initiator:\n+                responder_ids = path.get_responder_ids()\n+                coroutines = []\n+                for responder_id in responder_ids:\n+                    responder = path.get_responder(responder_id)\n+\n+                    # Create message and add send coroutine to task queue of the responder\n+                    message = DisconnectedMessage.create(\n+                        AddressType.server, responder_id, client.id)\n+                    responder.log.debug('Enqueueing disconnected message')\n+                    coroutines.append(responder.enqueue_task(responder.send(message)))\n+                yield from asyncio.gather(*coroutines)","path":"saltyrtc/server/server.py","position":26,"original_position":26,"commit_id":"bd8fff21abacd4a9da9c650a647ee31f5e076ef5","original_commit_id":"bd8fff21abacd4a9da9c650a647ee31f5e076ef5","user":{"login":"lgrahl","id":1793755,"avatar_url":"https://avatars3.githubusercontent.com/u/1793755?v=4","gravatar_id":"","url":"https://api.github.com/users/lgrahl","html_url":"https://github.com/lgrahl","followers_url":"https://api.github.com/users/lgrahl/followers","following_url":"https://api.github.com/users/lgrahl/following{/other_user}","gists_url":"https://api.github.com/users/lgrahl/gists{/gist_id}","starred_url":"https://api.github.com/users/lgrahl/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/lgrahl/subscriptions","organizations_url":"https://api.github.com/users/lgrahl/orgs","repos_url":"https://api.github.com/users/lgrahl/repos","events_url":"https://api.github.com/users/lgrahl/events{/privacy}","received_events_url":"https://api.github.com/users/lgrahl/received_events","type":"User","site_admin":false},"body":"Keep it.","created_at":"2018-04-26T13:54:43Z","updated_at":"2018-04-26T13:54:43Z","html_url":"https://github.com/saltyrtc/saltyrtc-server-python/pull/71#discussion_r184397718","pull_request_url":"https://api.github.com/repos/saltyrtc/saltyrtc-server-python/pulls/71","author_association":"OWNER","_links":{"self":{"href":"https://api.github.com/repos/saltyrtc/saltyrtc-server-python/pulls/comments/184397718"},"html":{"href":"https://github.com/saltyrtc/saltyrtc-server-python/pull/71#discussion_r184397718"},"pull_request":{"href":"https://api.github.com/repos/saltyrtc/saltyrtc-server-python/pulls/71"}},"in_reply_to_id":184321365},"pull_request":{"url":"https://api.github.com/repos/saltyrtc/saltyrtc-server-python/pulls/71","id":173569210,"html_url":"https://github.com/saltyrtc/saltyrtc-server-python/pull/71","diff_url":"https://github.com/saltyrtc/saltyrtc-server-python/pull/71.diff","patch_url":"https://github.com/saltyrtc/saltyrtc-server-python/pull/71.patch","issue_url":"https://api.github.com/repos/saltyrtc/saltyrtc-server-python/issues/71","number":71,"state":"open","locked":false,"title":"Support 'disconnected' message","user":{"login":"lgrahl","id":1793755,"avatar_url":"https://avatars3.githubusercontent.com/u/1793755?v=4","gravatar_id":"","url":"https://api.github.com/users/lgrahl","html_url":"https://github.com/lgrahl","followers_url":"https://api.github.com/users/lgrahl/followers","following_url":"https://api.github.com/users/lgrahl/following{/other_user}","gists_url":"https://api.github.com/users/lgrahl/gists{/gist_id}","starred_url":"https://api.github.com/users/lgrahl/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/lgrahl/subscriptions","organizations_url":"https://api.github.com/users/lgrahl/orgs","repos_url":"https://api.github.com/users/lgrahl/repos","events_url":"https://api.github.com/users/lgrahl/events{/privacy}","received_events_url":"https://api.github.com/users/lgrahl/received_events","type":"User","site_admin":false},"body":"This adds support for the 'disconnected' message type.\r\n\r\nTo do:\r\n\r\n* [ ] Fix mentioned race conditions\r\n* [ ] Write tests\r\n* [ ] Update existing tests to also check for 'disconnected'\r\n\r\nSee: https://github.com/saltyrtc/saltyrtc-meta/pull/145","created_at":"2018-03-07T20:48:37Z","updated_at":"2018-04-26T13:54:43Z","closed_at":null,"merged_at":null,"merge_commit_sha":"56a9ba3718bbadbf5cff19fb2fa8b4f0c89ee0a8","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[{"id":365305734,"url":"https://api.github.com/repos/saltyrtc/saltyrtc-server-python/labels/enhancement","name":"enhancement","color":"84b6eb","default":true}],"milestone":null,"commits_url":"https://api.github.com/repos/saltyrtc/saltyrtc-server-python/pulls/71/commits","review_comments_url":"https://api.github.com/repos/saltyrtc/saltyrtc-server-python/pulls/71/comments","review_comment_url":"https://api.github.com/repos/saltyrtc/saltyrtc-server-python/pulls/comments{/number}","comments_url":"https://api.github.com/repos/saltyrtc/saltyrtc-server-python/issues/71/comments","statuses_url":"https://api.github.com/repos/saltyrtc/saltyrtc-server-python/statuses/bd8fff21abacd4a9da9c650a647ee31f5e076ef5","head":{"label":"saltyrtc:disconnected-message","ref":"disconnected-message","sha":"bd8fff21abacd4a9da9c650a647ee31f5e076ef5","user":{"login":"saltyrtc","id":18709335,"avatar_url":"https://avatars3.githubusercontent.com/u/18709335?v=4","gravatar_id":"","url":"https://api.github.com/users/saltyrtc","html_url":"https://github.com/saltyrtc","followers_url":"https://api.github.com/users/saltyrtc/followers","following_url":"https://api.github.com/users/saltyrtc/following{/other_user}","gists_url":"https://api.github.com/users/saltyrtc/gists{/gist_id}","starred_url":"https://api.github.com/users/saltyrtc/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/saltyrtc/subscriptions","organizations_url":"https://api.github.com/users/saltyrtc/orgs","repos_url":"https://api.github.com/users/saltyrtc/repos","events_url":"https://api.github.com/users/saltyrtc/events{/privacy}","received_events_url":"https://api.github.com/users/saltyrtc/received_events","type":"Organization","site_admin":false},"repo":{"id":57252623,"name":"saltyrtc-server-python","full_name":"saltyrtc/saltyrtc-server-python","owner":{"login":"saltyrtc","id":18709335,"avatar_url":"https://avatars3.githubusercontent.com/u/18709335?v=4","gravatar_id":"","url":"https://api.github.com/users/saltyrtc","html_url":"https://github.com/saltyrtc","followers_url":"https://api.github.com/users/saltyrtc/followers","following_url":"https://api.github.com/users/saltyrtc/following{/other_user}","gists_url":"https://api.github.com/users/saltyrtc/gists{/gist_id}","starred_url":"https://api.github.com/users/saltyrtc/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/saltyrtc/subscriptions","organizations_url":"https://api.github.com/users/saltyrtc/orgs","repos_url":"https://api.github.com/users/saltyrtc/repos","events_url":"https://api.github.com/users/saltyrtc/events{/privacy}","received_events_url":"https://api.github.com/users/saltyrtc/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/saltyrtc/saltyrtc-server-python","description":"SaltyRTC signalling server implementation.","fork":false,"url":"https://api.github.com/repos/saltyrtc/saltyrtc-server-python","forks_url":"https://api.github.com/repos/saltyrtc/saltyrtc-server-python/forks","keys_url":"https://api.github.com/repos/saltyrtc/saltyrtc-server-python/keys{/key_id}","collaborators_url":"https://api.github.com/repos/saltyrtc/saltyrtc-server-python/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/saltyrtc/saltyrtc-server-python/teams","hooks_url":"https://api.github.com/repos/saltyrtc/saltyrtc-server-python/hooks","issue_events_url":"https://api.github.com/repos/saltyrtc/saltyrtc-server-python/issues/events{/number}","events_url":"https://api.github.com/repos/saltyrtc/saltyrtc-server-python/events","assignees_url":"https://api.github.com/repos/saltyrtc/saltyrtc-server-python/assignees{/user}","branches_url":"https://api.github.com/repos/saltyrtc/saltyrtc-server-python/branches{/branch}","tags_url":"https://api.github.com/repos/saltyrtc/saltyrtc-server-python/tags","blobs_url":"https://api.github.com/repos/saltyrtc/saltyrtc-server-python/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/saltyrtc/saltyrtc-server-python/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/saltyrtc/saltyrtc-server-python/git/refs{/sha}","trees_url":"https://api.github.com/repos/saltyrtc/saltyrtc-server-python/git/trees{/sha}","statuses_url":"https://api.github.com/repos/saltyrtc/saltyrtc-server-python/statuses/{sha}","languages_url":"https://api.github.com/repos/saltyrtc/saltyrtc-server-python/languages","stargazers_url":"https://api.github.com/repos/saltyrtc/saltyrtc-server-python/stargazers","contributors_url":"https://api.github.com/repos/saltyrtc/saltyrtc-server-python/contributors","subscribers_url":"https://api.github.com/repos/saltyrtc/saltyrtc-server-python/subscribers","subscription_url":"https://api.github.com/repos/saltyrtc/saltyrtc-server-python/subscription","commits_url":"https://api.github.com/repos/saltyrtc/saltyrtc-server-python/commits{/sha}","git_commits_url":"https://api.github.com/repos/saltyrtc/saltyrtc-server-python/git/commits{/sha}","comments_url":"https://api.github.com/repos/saltyrtc/saltyrtc-server-python/comments{/number}","issue_comment_url":"https://api.github.com/repos/saltyrtc/saltyrtc-server-python/issues/comments{/number}","contents_url":"https://api.github.com/repos/saltyrtc/saltyrtc-server-python/contents/{+path}","compare_url":"https://api.github.com/repos/saltyrtc/saltyrtc-server-python/compare/{base}...{head}","merges_url":"https://api.github.com/repos/saltyrtc/saltyrtc-server-python/merges","archive_url":"https://api.github.com/repos/saltyrtc/saltyrtc-server-python/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/saltyrtc/saltyrtc-server-python/downloads","issues_url":"https://api.github.com/repos/saltyrtc/saltyrtc-server-python/issues{/number}","pulls_url":"https://api.github.com/repos/saltyrtc/saltyrtc-server-python/pulls{/number}","milestones_url":"https://api.github.com/repos/saltyrtc/saltyrtc-server-python/milestones{/number}","notifications_url":"https://api.github.com/repos/saltyrtc/saltyrtc-server-python/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/saltyrtc/saltyrtc-server-python/labels{/name}","releases_url":"https://api.github.com/repos/saltyrtc/saltyrtc-server-python/releases{/id}","deployments_url":"https://api.github.com/repos/saltyrtc/saltyrtc-server-python/deployments","created_at":"2016-04-27T22:19:34Z","updated_at":"2018-02-18T14:38:07Z","pushed_at":"2018-04-26T09:10:35Z","git_url":"git://github.com/saltyrtc/saltyrtc-server-python.git","ssh_url":"git@github.com:saltyrtc/saltyrtc-server-python.git","clone_url":"https://github.com/saltyrtc/saltyrtc-server-python.git","svn_url":"https://github.com/saltyrtc/saltyrtc-server-python","homepage":null,"size":269,"stargazers_count":18,"watchers_count":18,"language":"Python","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":3,"mirror_url":null,"archived":false,"open_issues_count":19,"license":{"key":"mit","name":"MIT License","spdx_id":"MIT","url":"https://api.github.com/licenses/mit"},"forks":3,"open_issues":19,"watchers":18,"default_branch":"master"}},"base":{"label":"saltyrtc:master","ref":"master","sha":"f902c2762dba977fff5a247574f9dc5eeebf8063","user":{"login":"saltyrtc","id":18709335,"avatar_url":"https://avatars3.githubusercontent.com/u/18709335?v=4","gravatar_id":"","url":"https://api.github.com/users/saltyrtc","html_url":"https://github.com/saltyrtc","followers_url":"https://api.github.com/users/saltyrtc/followers","following_url":"https://api.github.com/users/saltyrtc/following{/other_user}","gists_url":"https://api.github.com/users/saltyrtc/gists{/gist_id}","starred_url":"https://api.github.com/users/saltyrtc/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/saltyrtc/subscriptions","organizations_url":"https://api.github.com/users/saltyrtc/orgs","repos_url":"https://api.github.com/users/saltyrtc/repos","events_url":"https://api.github.com/users/saltyrtc/events{/privacy}","received_events_url":"https://api.github.com/users/saltyrtc/received_events","type":"Organization","site_admin":false},"repo":{"id":57252623,"name":"saltyrtc-server-python","full_name":"saltyrtc/saltyrtc-server-python","owner":{"login":"saltyrtc","id":18709335,"avatar_url":"https://avatars3.githubusercontent.com/u/18709335?v=4","gravatar_id":"","url":"https://api.github.com/users/saltyrtc","html_url":"https://github.com/saltyrtc","followers_url":"https://api.github.com/users/saltyrtc/followers","following_url":"https://api.github.com/users/saltyrtc/following{/other_user}","gists_url":"https://api.github.com/users/saltyrtc/gists{/gist_id}","starred_url":"https://api.github.com/users/saltyrtc/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/saltyrtc/subscriptions","organizations_url":"https://api.github.com/users/saltyrtc/orgs","repos_url":"https://api.github.com/users/saltyrtc/repos","events_url":"https://api.github.com/users/saltyrtc/events{/privacy}","received_events_url":"https://api.github.com/users/saltyrtc/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/saltyrtc/saltyrtc-server-python","description":"SaltyRTC signalling server implementation.","fork":false,"url":"https://api.github.com/repos/saltyrtc/saltyrtc-server-python","forks_url":"https://api.github.com/repos/saltyrtc/saltyrtc-server-python/forks","keys_url":"https://api.github.com/repos/saltyrtc/saltyrtc-server-python/keys{/key_id}","collaborators_url":"https://api.github.com/repos/saltyrtc/saltyrtc-server-python/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/saltyrtc/saltyrtc-server-python/teams","hooks_url":"https://api.github.com/repos/saltyrtc/saltyrtc-server-python/hooks","issue_events_url":"https://api.github.com/repos/saltyrtc/saltyrtc-server-python/issues/events{/number}","events_url":"https://api.github.com/repos/saltyrtc/saltyrtc-server-python/events","assignees_url":"https://api.github.com/repos/saltyrtc/saltyrtc-server-python/assignees{/user}","branches_url":"https://api.github.com/repos/saltyrtc/saltyrtc-server-python/branches{/branch}","tags_url":"https://api.github.com/repos/saltyrtc/saltyrtc-server-python/tags","blobs_url":"https://api.github.com/repos/saltyrtc/saltyrtc-server-python/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/saltyrtc/saltyrtc-server-python/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/saltyrtc/saltyrtc-server-python/git/refs{/sha}","trees_url":"https://api.github.com/repos/saltyrtc/saltyrtc-server-python/git/trees{/sha}","statuses_url":"https://api.github.com/repos/saltyrtc/saltyrtc-server-python/statuses/{sha}","languages_url":"https://api.github.com/repos/saltyrtc/saltyrtc-server-python/languages","stargazers_url":"https://api.github.com/repos/saltyrtc/saltyrtc-server-python/stargazers","contributors_url":"https://api.github.com/repos/saltyrtc/saltyrtc-server-python/contributors","subscribers_url":"https://api.github.com/repos/saltyrtc/saltyrtc-server-python/subscribers","subscription_url":"https://api.github.com/repos/saltyrtc/saltyrtc-server-python/subscription","commits_url":"https://api.github.com/repos/saltyrtc/saltyrtc-server-python/commits{/sha}","git_commits_url":"https://api.github.com/repos/saltyrtc/saltyrtc-server-python/git/commits{/sha}","comments_url":"https://api.github.com/repos/saltyrtc/saltyrtc-server-python/comments{/number}","issue_comment_url":"https://api.github.com/repos/saltyrtc/saltyrtc-server-python/issues/comments{/number}","contents_url":"https://api.github.com/repos/saltyrtc/saltyrtc-server-python/contents/{+path}","compare_url":"https://api.github.com/repos/saltyrtc/saltyrtc-server-python/compare/{base}...{head}","merges_url":"https://api.github.com/repos/saltyrtc/saltyrtc-server-python/merges","archive_url":"https://api.github.com/repos/saltyrtc/saltyrtc-server-python/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/saltyrtc/saltyrtc-server-python/downloads","issues_url":"https://api.github.com/repos/saltyrtc/saltyrtc-server-python/issues{/number}","pulls_url":"https://api.github.com/repos/saltyrtc/saltyrtc-server-python/pulls{/number}","milestones_url":"https://api.github.com/repos/saltyrtc/saltyrtc-server-python/milestones{/number}","notifications_url":"https://api.github.com/repos/saltyrtc/saltyrtc-server-python/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/saltyrtc/saltyrtc-server-python/labels{/name}","releases_url":"https://api.github.com/repos/saltyrtc/saltyrtc-server-python/releases{/id}","deployments_url":"https://api.github.com/repos/saltyrtc/saltyrtc-server-python/deployments","created_at":"2016-04-27T22:19:34Z","updated_at":"2018-02-18T14:38:07Z","pushed_at":"2018-04-26T09:10:35Z","git_url":"git://github.com/saltyrtc/saltyrtc-server-python.git","ssh_url":"git@github.com:saltyrtc/saltyrtc-server-python.git","clone_url":"https://github.com/saltyrtc/saltyrtc-server-python.git","svn_url":"https://github.com/saltyrtc/saltyrtc-server-python","homepage":null,"size":269,"stargazers_count":18,"watchers_count":18,"language":"Python","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":3,"mirror_url":null,"archived":false,"open_issues_count":19,"license":{"key":"mit","name":"MIT License","spdx_id":"MIT","url":"https://api.github.com/licenses/mit"},"forks":3,"open_issues":19,"watchers":18,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/saltyrtc/saltyrtc-server-python/pulls/71"},"html":{"href":"https://github.com/saltyrtc/saltyrtc-server-python/pull/71"},"issue":{"href":"https://api.github.com/repos/saltyrtc/saltyrtc-server-python/issues/71"},"comments":{"href":"https://api.github.com/repos/saltyrtc/saltyrtc-server-python/issues/71/comments"},"review_comments":{"href":"https://api.github.com/repos/saltyrtc/saltyrtc-server-python/pulls/71/comments"},"review_comment":{"href":"https://api.github.com/repos/saltyrtc/saltyrtc-server-python/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/saltyrtc/saltyrtc-server-python/pulls/71/commits"},"statuses":{"href":"https://api.github.com/repos/saltyrtc/saltyrtc-server-python/statuses/bd8fff21abacd4a9da9c650a647ee31f5e076ef5"}},"author_association":"OWNER"}}
{"actor":{"display_login":"lgrahl"}}