{"action":"created","issue":{"url":"https://api.github.com/repos/ethereum/go-ethereum/issues/1996","labels_url":"https://api.github.com/repos/ethereum/go-ethereum/issues/1996/labels{/name}","comments_url":"https://api.github.com/repos/ethereum/go-ethereum/issues/1996/comments","events_url":"https://api.github.com/repos/ethereum/go-ethereum/issues/1996/events","html_url":"https://github.com/ethereum/go-ethereum/pull/1996","id":118097881,"number":1996,"title":"whisper: fixed broadcast race","user":{"login":"obscuren","id":6264126,"avatar_url":"https://avatars.githubusercontent.com/u/6264126?v=3","gravatar_id":"","url":"https://api.github.com/users/obscuren","html_url":"https://github.com/obscuren","followers_url":"https://api.github.com/users/obscuren/followers","following_url":"https://api.github.com/users/obscuren/following{/other_user}","gists_url":"https://api.github.com/users/obscuren/gists{/gist_id}","starred_url":"https://api.github.com/users/obscuren/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/obscuren/subscriptions","organizations_url":"https://api.github.com/users/obscuren/orgs","repos_url":"https://api.github.com/users/obscuren/repos","events_url":"https://api.github.com/users/obscuren/events{/privacy}","received_events_url":"https://api.github.com/users/obscuren/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/ethereum/go-ethereum/labels/bug","name":"bug","color":"fc2929"},{"url":"https://api.github.com/repos/ethereum/go-ethereum/labels/review","name":"review","color":"fad8c7"},{"url":"https://api.github.com/repos/ethereum/go-ethereum/labels/whisper","name":"whisper","color":"d4c5f9"}],"state":"open","locked":false,"assignee":null,"milestone":{"url":"https://api.github.com/repos/ethereum/go-ethereum/milestones/20","html_url":"https://github.com/ethereum/go-ethereum/milestones/1.4.0","labels_url":"https://api.github.com/repos/ethereum/go-ethereum/milestones/20/labels","id":1299388,"number":20,"title":"1.4.0","description":"","creator":{"login":"obscuren","id":6264126,"avatar_url":"https://avatars.githubusercontent.com/u/6264126?v=3","gravatar_id":"","url":"https://api.github.com/users/obscuren","html_url":"https://github.com/obscuren","followers_url":"https://api.github.com/users/obscuren/followers","following_url":"https://api.github.com/users/obscuren/following{/other_user}","gists_url":"https://api.github.com/users/obscuren/gists{/gist_id}","starred_url":"https://api.github.com/users/obscuren/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/obscuren/subscriptions","organizations_url":"https://api.github.com/users/obscuren/orgs","repos_url":"https://api.github.com/users/obscuren/repos","events_url":"https://api.github.com/users/obscuren/events{/privacy}","received_events_url":"https://api.github.com/users/obscuren/received_events","type":"User","site_admin":false},"open_issues":13,"closed_issues":0,"state":"open","created_at":"2015-09-10T13:53:50Z","updated_at":"2015-11-24T12:40:26Z","due_on":null,"closed_at":null},"comments":5,"created_at":"2015-11-20T18:27:53Z","updated_at":"2015-11-25T11:11:55Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/ethereum/go-ethereum/pulls/1996","html_url":"https://github.com/ethereum/go-ethereum/pull/1996","diff_url":"https://github.com/ethereum/go-ethereum/pull/1996.diff","patch_url":"https://github.com/ethereum/go-ethereum/pull/1996.patch"},"body":"Whisper's expire and broadcast loops happen in two separate go routines.\r\nWhenever an envelope is being expired it's removed from the set of\r\nenvelopes and it looses all information about the envelope, including\r\nthe \"known hash\". After the envelope has been removed it can be\r\nre-accepted by a broadcasting peer putting back the envelope in the set\r\nof envelopes. Since the envelope broadcast loop is separate of the\r\nexpire loop expired messages may be broadcast to other peer, resulting\r\nin messages **never** being dropped.\r\n\r\nThis PR includes an expire check before adding new messages to the set\r\nof envelopes."},"comment":{"url":"https://api.github.com/repos/ethereum/go-ethereum/issues/comments/159574575","html_url":"https://github.com/ethereum/go-ethereum/pull/1996#issuecomment-159574575","issue_url":"https://api.github.com/repos/ethereum/go-ethereum/issues/1996","id":159574575,"user":{"login":"obscuren","id":6264126,"avatar_url":"https://avatars.githubusercontent.com/u/6264126?v=3","gravatar_id":"","url":"https://api.github.com/users/obscuren","html_url":"https://github.com/obscuren","followers_url":"https://api.github.com/users/obscuren/followers","following_url":"https://api.github.com/users/obscuren/following{/other_user}","gists_url":"https://api.github.com/users/obscuren/gists{/gist_id}","starred_url":"https://api.github.com/users/obscuren/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/obscuren/subscriptions","organizations_url":"https://api.github.com/users/obscuren/orgs","repos_url":"https://api.github.com/users/obscuren/repos","events_url":"https://api.github.com/users/obscuren/events{/privacy}","received_events_url":"https://api.github.com/users/obscuren/received_events","type":"User","site_admin":false},"created_at":"2015-11-25T11:11:55Z","updated_at":"2015-11-25T11:11:55Z","body":"Alright, test has been replaced. Not directly related to the fixes them self I think we should address them in a separate PR next time. "}}