{"action":"created","comment":{"url":"https://api.github.com/repos/bigchaindb/bigchaindb/pulls/comments/206498327","pull_request_review_id":141919852,"id":206498327,"node_id":"MDI0OlB1bGxSZXF1ZXN0UmV2aWV3Q29tbWVudDIwNjQ5ODMyNw==","diff_hunk":"@@ -67,7 +67,7 @@ def get_subscriber_queue(self, event_types=None):\n         \"\"\"\n \n         try:\n-            self.started_queue.get_nowait()\n+            self.started_queue.get(timeout=0.01)","path":"bigchaindb/events.py","position":5,"original_position":5,"commit_id":"5ecd8fb57c613c1bb4362c3860934c7a0003dff2","original_commit_id":"5ecd8fb57c613c1bb4362c3860934c7a0003dff2","user":{"login":"ldmberman","id":4797754,"node_id":"MDQ6VXNlcjQ3OTc3NTQ=","avatar_url":"https://avatars3.githubusercontent.com/u/4797754?v=4","gravatar_id":"","url":"https://api.github.com/users/ldmberman","html_url":"https://github.com/ldmberman","followers_url":"https://api.github.com/users/ldmberman/followers","following_url":"https://api.github.com/users/ldmberman/following{/other_user}","gists_url":"https://api.github.com/users/ldmberman/gists{/gist_id}","starred_url":"https://api.github.com/users/ldmberman/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ldmberman/subscriptions","organizations_url":"https://api.github.com/users/ldmberman/orgs","repos_url":"https://api.github.com/users/ldmberman/repos","events_url":"https://api.github.com/users/ldmberman/events{/privacy}","received_events_url":"https://api.github.com/users/ldmberman/received_events","type":"User","site_admin":false},"body":"Since CI often fails for us here it makes sense to stay on the safe side and set a second. It only impacts the performance of the unsuccessful case. Do you expect failed retrievals to happen a lot? I suppose, we should not expect them to happen often so it's ok to wait for a second if it happens.","created_at":"2018-07-31T12:01:48Z","updated_at":"2018-07-31T12:01:49Z","html_url":"https://github.com/bigchaindb/bigchaindb/pull/2423#discussion_r206498327","pull_request_url":"https://api.github.com/repos/bigchaindb/bigchaindb/pulls/2423","author_association":"MEMBER","_links":{"self":{"href":"https://api.github.com/repos/bigchaindb/bigchaindb/pulls/comments/206498327"},"html":{"href":"https://github.com/bigchaindb/bigchaindb/pull/2423#discussion_r206498327"},"pull_request":{"href":"https://api.github.com/repos/bigchaindb/bigchaindb/pulls/2423"}},"in_reply_to_id":206470056},"pull_request":{"url":"https://api.github.com/repos/bigchaindb/bigchaindb/pulls/2423","id":205055015,"node_id":"MDExOlB1bGxSZXF1ZXN0MjA1MDU1MDE1","html_url":"https://github.com/bigchaindb/bigchaindb/pull/2423","diff_url":"https://github.com/bigchaindb/bigchaindb/pull/2423.diff","patch_url":"https://github.com/bigchaindb/bigchaindb/pull/2423.patch","issue_url":"https://api.github.com/repos/bigchaindb/bigchaindb/issues/2423","number":2423,"state":"open","locked":false,"title":"Problem: No wait when getting value from queue","user":{"login":"kansi","id":4709940,"node_id":"MDQ6VXNlcjQ3MDk5NDA=","avatar_url":"https://avatars2.githubusercontent.com/u/4709940?v=4","gravatar_id":"","url":"https://api.github.com/users/kansi","html_url":"https://github.com/kansi","followers_url":"https://api.github.com/users/kansi/followers","following_url":"https://api.github.com/users/kansi/following{/other_user}","gists_url":"https://api.github.com/users/kansi/gists{/gist_id}","starred_url":"https://api.github.com/users/kansi/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kansi/subscriptions","organizations_url":"https://api.github.com/users/kansi/orgs","repos_url":"https://api.github.com/users/kansi/repos","events_url":"https://api.github.com/users/kansi/events{/privacy}","received_events_url":"https://api.github.com/users/kansi/received_events","type":"User","site_admin":false},"body":"Solution: Random failure of test [`tests/test_events.py::test_event_handler_raises_when_called_after_start`](https://github.com/bigchaindb/bigchaindb/blob/master/tests/test_events.py#L42) seems to be because of `get_nowait` which returns way to quickly even when the queue has data i.e. the test expect the queue to have the message `'STARTED'` which should be returned when `.get_nowait()` is called. But since `get_nowait()` returns without waiting which causes a queue `Empty` exception rather than `Runtime` exception.","created_at":"2018-07-31T09:47:27Z","updated_at":"2018-07-31T12:01:49Z","closed_at":null,"merged_at":null,"merge_commit_sha":"880eea63d1679505178ac04453f9c721a3c63e7a","assignee":null,"assignees":[],"requested_reviewers":[{"login":"ldmberman","id":4797754,"node_id":"MDQ6VXNlcjQ3OTc3NTQ=","avatar_url":"https://avatars3.githubusercontent.com/u/4797754?v=4","gravatar_id":"","url":"https://api.github.com/users/ldmberman","html_url":"https://github.com/ldmberman","followers_url":"https://api.github.com/users/ldmberman/followers","following_url":"https://api.github.com/users/ldmberman/following{/other_user}","gists_url":"https://api.github.com/users/ldmberman/gists{/gist_id}","starred_url":"https://api.github.com/users/ldmberman/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ldmberman/subscriptions","organizations_url":"https://api.github.com/users/ldmberman/orgs","repos_url":"https://api.github.com/users/ldmberman/repos","events_url":"https://api.github.com/users/ldmberman/events{/privacy}","received_events_url":"https://api.github.com/users/ldmberman/received_events","type":"User","site_admin":false},{"login":"muawiakh","id":8788382,"node_id":"MDQ6VXNlcjg3ODgzODI=","avatar_url":"https://avatars2.githubusercontent.com/u/8788382?v=4","gravatar_id":"","url":"https://api.github.com/users/muawiakh","html_url":"https://github.com/muawiakh","followers_url":"https://api.github.com/users/muawiakh/followers","following_url":"https://api.github.com/users/muawiakh/following{/other_user}","gists_url":"https://api.github.com/users/muawiakh/gists{/gist_id}","starred_url":"https://api.github.com/users/muawiakh/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/muawiakh/subscriptions","organizations_url":"https://api.github.com/users/muawiakh/orgs","repos_url":"https://api.github.com/users/muawiakh/repos","events_url":"https://api.github.com/users/muawiakh/events{/privacy}","received_events_url":"https://api.github.com/users/muawiakh/received_events","type":"User","site_admin":false}],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/bigchaindb/bigchaindb/pulls/2423/commits","review_comments_url":"https://api.github.com/repos/bigchaindb/bigchaindb/pulls/2423/comments","review_comment_url":"https://api.github.com/repos/bigchaindb/bigchaindb/pulls/comments{/number}","comments_url":"https://api.github.com/repos/bigchaindb/bigchaindb/issues/2423/comments","statuses_url":"https://api.github.com/repos/bigchaindb/bigchaindb/statuses/5ecd8fb57c613c1bb4362c3860934c7a0003dff2","head":{"label":"kansi:iss/random-event-test-failure","ref":"iss/random-event-test-failure","sha":"5ecd8fb57c613c1bb4362c3860934c7a0003dff2","user":{"login":"kansi","id":4709940,"node_id":"MDQ6VXNlcjQ3MDk5NDA=","avatar_url":"https://avatars2.githubusercontent.com/u/4709940?v=4","gravatar_id":"","url":"https://api.github.com/users/kansi","html_url":"https://github.com/kansi","followers_url":"https://api.github.com/users/kansi/followers","following_url":"https://api.github.com/users/kansi/following{/other_user}","gists_url":"https://api.github.com/users/kansi/gists{/gist_id}","starred_url":"https://api.github.com/users/kansi/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kansi/subscriptions","organizations_url":"https://api.github.com/users/kansi/orgs","repos_url":"https://api.github.com/users/kansi/repos","events_url":"https://api.github.com/users/kansi/events{/privacy}","received_events_url":"https://api.github.com/users/kansi/received_events","type":"User","site_admin":false},"repo":{"id":122710041,"node_id":"MDEwOlJlcG9zaXRvcnkxMjI3MTAwNDE=","name":"bigchaindb","full_name":"kansi/bigchaindb","owner":{"login":"kansi","id":4709940,"node_id":"MDQ6VXNlcjQ3MDk5NDA=","avatar_url":"https://avatars2.githubusercontent.com/u/4709940?v=4","gravatar_id":"","url":"https://api.github.com/users/kansi","html_url":"https://github.com/kansi","followers_url":"https://api.github.com/users/kansi/followers","following_url":"https://api.github.com/users/kansi/following{/other_user}","gists_url":"https://api.github.com/users/kansi/gists{/gist_id}","starred_url":"https://api.github.com/users/kansi/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kansi/subscriptions","organizations_url":"https://api.github.com/users/kansi/orgs","repos_url":"https://api.github.com/users/kansi/repos","events_url":"https://api.github.com/users/kansi/events{/privacy}","received_events_url":"https://api.github.com/users/kansi/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/kansi/bigchaindb","description":"Meet BigchainDB. The blockchain database.","fork":true,"url":"https://api.github.com/repos/kansi/bigchaindb","forks_url":"https://api.github.com/repos/kansi/bigchaindb/forks","keys_url":"https://api.github.com/repos/kansi/bigchaindb/keys{/key_id}","collaborators_url":"https://api.github.com/repos/kansi/bigchaindb/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/kansi/bigchaindb/teams","hooks_url":"https://api.github.com/repos/kansi/bigchaindb/hooks","issue_events_url":"https://api.github.com/repos/kansi/bigchaindb/issues/events{/number}","events_url":"https://api.github.com/repos/kansi/bigchaindb/events","assignees_url":"https://api.github.com/repos/kansi/bigchaindb/assignees{/user}","branches_url":"https://api.github.com/repos/kansi/bigchaindb/branches{/branch}","tags_url":"https://api.github.com/repos/kansi/bigchaindb/tags","blobs_url":"https://api.github.com/repos/kansi/bigchaindb/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/kansi/bigchaindb/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/kansi/bigchaindb/git/refs{/sha}","trees_url":"https://api.github.com/repos/kansi/bigchaindb/git/trees{/sha}","statuses_url":"https://api.github.com/repos/kansi/bigchaindb/statuses/{sha}","languages_url":"https://api.github.com/repos/kansi/bigchaindb/languages","stargazers_url":"https://api.github.com/repos/kansi/bigchaindb/stargazers","contributors_url":"https://api.github.com/repos/kansi/bigchaindb/contributors","subscribers_url":"https://api.github.com/repos/kansi/bigchaindb/subscribers","subscription_url":"https://api.github.com/repos/kansi/bigchaindb/subscription","commits_url":"https://api.github.com/repos/kansi/bigchaindb/commits{/sha}","git_commits_url":"https://api.github.com/repos/kansi/bigchaindb/git/commits{/sha}","comments_url":"https://api.github.com/repos/kansi/bigchaindb/comments{/number}","issue_comment_url":"https://api.github.com/repos/kansi/bigchaindb/issues/comments{/number}","contents_url":"https://api.github.com/repos/kansi/bigchaindb/contents/{+path}","compare_url":"https://api.github.com/repos/kansi/bigchaindb/compare/{base}...{head}","merges_url":"https://api.github.com/repos/kansi/bigchaindb/merges","archive_url":"https://api.github.com/repos/kansi/bigchaindb/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/kansi/bigchaindb/downloads","issues_url":"https://api.github.com/repos/kansi/bigchaindb/issues{/number}","pulls_url":"https://api.github.com/repos/kansi/bigchaindb/pulls{/number}","milestones_url":"https://api.github.com/repos/kansi/bigchaindb/milestones{/number}","notifications_url":"https://api.github.com/repos/kansi/bigchaindb/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/kansi/bigchaindb/labels{/name}","releases_url":"https://api.github.com/repos/kansi/bigchaindb/releases{/id}","deployments_url":"https://api.github.com/repos/kansi/bigchaindb/deployments","created_at":"2018-02-24T06:19:59Z","updated_at":"2018-06-12T08:41:07Z","pushed_at":"2018-07-31T11:48:35Z","git_url":"git://github.com/kansi/bigchaindb.git","ssh_url":"git@github.com:kansi/bigchaindb.git","clone_url":"https://github.com/kansi/bigchaindb.git","svn_url":"https://github.com/kansi/bigchaindb","homepage":"https://www.bigchaindb.com/","size":10204,"stargazers_count":0,"watchers_count":0,"language":"Python","has_issues":false,"has_projects":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"open_issues_count":0,"license":{"key":"apache-2.0","name":"Apache License 2.0","spdx_id":"Apache-2.0","url":"https://api.github.com/licenses/apache-2.0","node_id":"MDc6TGljZW5zZTI="},"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"bigchaindb:master","ref":"master","sha":"4795a78d4901918590d500858dad83a14685a330","user":{"login":"bigchaindb","id":17097586,"node_id":"MDEyOk9yZ2FuaXphdGlvbjE3MDk3NTg2","avatar_url":"https://avatars0.githubusercontent.com/u/17097586?v=4","gravatar_id":"","url":"https://api.github.com/users/bigchaindb","html_url":"https://github.com/bigchaindb","followers_url":"https://api.github.com/users/bigchaindb/followers","following_url":"https://api.github.com/users/bigchaindb/following{/other_user}","gists_url":"https://api.github.com/users/bigchaindb/gists{/gist_id}","starred_url":"https://api.github.com/users/bigchaindb/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bigchaindb/subscriptions","organizations_url":"https://api.github.com/users/bigchaindb/orgs","repos_url":"https://api.github.com/users/bigchaindb/repos","events_url":"https://api.github.com/users/bigchaindb/events{/privacy}","received_events_url":"https://api.github.com/users/bigchaindb/received_events","type":"Organization","site_admin":false},"repo":{"id":51290852,"node_id":"MDEwOlJlcG9zaXRvcnk1MTI5MDg1Mg==","name":"bigchaindb","full_name":"bigchaindb/bigchaindb","owner":{"login":"bigchaindb","id":17097586,"node_id":"MDEyOk9yZ2FuaXphdGlvbjE3MDk3NTg2","avatar_url":"https://avatars0.githubusercontent.com/u/17097586?v=4","gravatar_id":"","url":"https://api.github.com/users/bigchaindb","html_url":"https://github.com/bigchaindb","followers_url":"https://api.github.com/users/bigchaindb/followers","following_url":"https://api.github.com/users/bigchaindb/following{/other_user}","gists_url":"https://api.github.com/users/bigchaindb/gists{/gist_id}","starred_url":"https://api.github.com/users/bigchaindb/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bigchaindb/subscriptions","organizations_url":"https://api.github.com/users/bigchaindb/orgs","repos_url":"https://api.github.com/users/bigchaindb/repos","events_url":"https://api.github.com/users/bigchaindb/events{/privacy}","received_events_url":"https://api.github.com/users/bigchaindb/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/bigchaindb/bigchaindb","description":"Meet BigchainDB. The blockchain database.","fork":false,"url":"https://api.github.com/repos/bigchaindb/bigchaindb","forks_url":"https://api.github.com/repos/bigchaindb/bigchaindb/forks","keys_url":"https://api.github.com/repos/bigchaindb/bigchaindb/keys{/key_id}","collaborators_url":"https://api.github.com/repos/bigchaindb/bigchaindb/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/bigchaindb/bigchaindb/teams","hooks_url":"https://api.github.com/repos/bigchaindb/bigchaindb/hooks","issue_events_url":"https://api.github.com/repos/bigchaindb/bigchaindb/issues/events{/number}","events_url":"https://api.github.com/repos/bigchaindb/bigchaindb/events","assignees_url":"https://api.github.com/repos/bigchaindb/bigchaindb/assignees{/user}","branches_url":"https://api.github.com/repos/bigchaindb/bigchaindb/branches{/branch}","tags_url":"https://api.github.com/repos/bigchaindb/bigchaindb/tags","blobs_url":"https://api.github.com/repos/bigchaindb/bigchaindb/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/bigchaindb/bigchaindb/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/bigchaindb/bigchaindb/git/refs{/sha}","trees_url":"https://api.github.com/repos/bigchaindb/bigchaindb/git/trees{/sha}","statuses_url":"https://api.github.com/repos/bigchaindb/bigchaindb/statuses/{sha}","languages_url":"https://api.github.com/repos/bigchaindb/bigchaindb/languages","stargazers_url":"https://api.github.com/repos/bigchaindb/bigchaindb/stargazers","contributors_url":"https://api.github.com/repos/bigchaindb/bigchaindb/contributors","subscribers_url":"https://api.github.com/repos/bigchaindb/bigchaindb/subscribers","subscription_url":"https://api.github.com/repos/bigchaindb/bigchaindb/subscription","commits_url":"https://api.github.com/repos/bigchaindb/bigchaindb/commits{/sha}","git_commits_url":"https://api.github.com/repos/bigchaindb/bigchaindb/git/commits{/sha}","comments_url":"https://api.github.com/repos/bigchaindb/bigchaindb/comments{/number}","issue_comment_url":"https://api.github.com/repos/bigchaindb/bigchaindb/issues/comments{/number}","contents_url":"https://api.github.com/repos/bigchaindb/bigchaindb/contents/{+path}","compare_url":"https://api.github.com/repos/bigchaindb/bigchaindb/compare/{base}...{head}","merges_url":"https://api.github.com/repos/bigchaindb/bigchaindb/merges","archive_url":"https://api.github.com/repos/bigchaindb/bigchaindb/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/bigchaindb/bigchaindb/downloads","issues_url":"https://api.github.com/repos/bigchaindb/bigchaindb/issues{/number}","pulls_url":"https://api.github.com/repos/bigchaindb/bigchaindb/pulls{/number}","milestones_url":"https://api.github.com/repos/bigchaindb/bigchaindb/milestones{/number}","notifications_url":"https://api.github.com/repos/bigchaindb/bigchaindb/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/bigchaindb/bigchaindb/labels{/name}","releases_url":"https://api.github.com/repos/bigchaindb/bigchaindb/releases{/id}","deployments_url":"https://api.github.com/repos/bigchaindb/bigchaindb/deployments","created_at":"2016-02-08T10:12:58Z","updated_at":"2018-07-31T07:16:39Z","pushed_at":"2018-07-31T11:48:37Z","git_url":"git://github.com/bigchaindb/bigchaindb.git","ssh_url":"git@github.com:bigchaindb/bigchaindb.git","clone_url":"https://github.com/bigchaindb/bigchaindb.git","svn_url":"https://github.com/bigchaindb/bigchaindb","homepage":"https://www.bigchaindb.com/","size":9272,"stargazers_count":2732,"watchers_count":2732,"language":"Python","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":524,"mirror_url":null,"archived":false,"open_issues_count":162,"license":{"key":"apache-2.0","name":"Apache License 2.0","spdx_id":"Apache-2.0","url":"https://api.github.com/licenses/apache-2.0","node_id":"MDc6TGljZW5zZTI="},"forks":524,"open_issues":162,"watchers":2732,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/bigchaindb/bigchaindb/pulls/2423"},"html":{"href":"https://github.com/bigchaindb/bigchaindb/pull/2423"},"issue":{"href":"https://api.github.com/repos/bigchaindb/bigchaindb/issues/2423"},"comments":{"href":"https://api.github.com/repos/bigchaindb/bigchaindb/issues/2423/comments"},"review_comments":{"href":"https://api.github.com/repos/bigchaindb/bigchaindb/pulls/2423/comments"},"review_comment":{"href":"https://api.github.com/repos/bigchaindb/bigchaindb/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/bigchaindb/bigchaindb/pulls/2423/commits"},"statuses":{"href":"https://api.github.com/repos/bigchaindb/bigchaindb/statuses/5ecd8fb57c613c1bb4362c3860934c7a0003dff2"}},"author_association":"MEMBER"}}
{"actor":{"display_login":"ldmberman"}}