{"action":"closed","issue":{"url":"https://api.github.com/repos/tdauth/scala-futures-promises/issues/13","repository_url":"https://api.github.com/repos/tdauth/scala-futures-promises","labels_url":"https://api.github.com/repos/tdauth/scala-futures-promises/issues/13/labels{/name}","comments_url":"https://api.github.com/repos/tdauth/scala-futures-promises/issues/13/comments","events_url":"https://api.github.com/repos/tdauth/scala-futures-promises/issues/13/events","html_url":"https://github.com/tdauth/scala-futures-promises/issues/13","id":362251230,"node_id":"MDU6SXNzdWUzNjIyNTEyMzA=","number":13,"title":"Fix data race bug in firstN and firstNSucc","user":{"login":"tdauth","id":19553237,"node_id":"MDQ6VXNlcjE5NTUzMjM3","avatar_url":"https://avatars1.githubusercontent.com/u/19553237?v=4","gravatar_id":"","url":"https://api.github.com/users/tdauth","html_url":"https://github.com/tdauth","followers_url":"https://api.github.com/users/tdauth/followers","following_url":"https://api.github.com/users/tdauth/following{/other_user}","gists_url":"https://api.github.com/users/tdauth/gists{/gist_id}","starred_url":"https://api.github.com/users/tdauth/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tdauth/subscriptions","organizations_url":"https://api.github.com/users/tdauth/orgs","repos_url":"https://api.github.com/users/tdauth/repos","events_url":"https://api.github.com/users/tdauth/events{/privacy}","received_events_url":"https://api.github.com/users/tdauth/received_events","type":"User","site_admin":false},"labels":[{"id":971106108,"node_id":"MDU6TGFiZWw5NzExMDYxMDg=","url":"https://api.github.com/repos/tdauth/scala-futures-promises/labels/bug","name":"bug","color":"d73a4a","default":true}],"state":"closed","locked":false,"assignee":{"login":"tdauth","id":19553237,"node_id":"MDQ6VXNlcjE5NTUzMjM3","avatar_url":"https://avatars1.githubusercontent.com/u/19553237?v=4","gravatar_id":"","url":"https://api.github.com/users/tdauth","html_url":"https://github.com/tdauth","followers_url":"https://api.github.com/users/tdauth/followers","following_url":"https://api.github.com/users/tdauth/following{/other_user}","gists_url":"https://api.github.com/users/tdauth/gists{/gist_id}","starred_url":"https://api.github.com/users/tdauth/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tdauth/subscriptions","organizations_url":"https://api.github.com/users/tdauth/orgs","repos_url":"https://api.github.com/users/tdauth/repos","events_url":"https://api.github.com/users/tdauth/events{/privacy}","received_events_url":"https://api.github.com/users/tdauth/received_events","type":"User","site_admin":false},"assignees":[{"login":"tdauth","id":19553237,"node_id":"MDQ6VXNlcjE5NTUzMjM3","avatar_url":"https://avatars1.githubusercontent.com/u/19553237?v=4","gravatar_id":"","url":"https://api.github.com/users/tdauth","html_url":"https://github.com/tdauth","followers_url":"https://api.github.com/users/tdauth/followers","following_url":"https://api.github.com/users/tdauth/following{/other_user}","gists_url":"https://api.github.com/users/tdauth/gists{/gist_id}","starred_url":"https://api.github.com/users/tdauth/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tdauth/subscriptions","organizations_url":"https://api.github.com/users/tdauth/orgs","repos_url":"https://api.github.com/users/tdauth/repos","events_url":"https://api.github.com/users/tdauth/events{/privacy}","received_events_url":"https://api.github.com/users/tdauth/received_events","type":"User","site_admin":false}],"milestone":null,"comments":0,"created_at":"2018-09-20T15:48:45Z","updated_at":"2018-09-23T12:35:02Z","closed_at":"2018-09-23T12:35:02Z","author_association":"OWNER","body":"There is a data race bug in the firstN and firstNSucc implementations. Make sure that the vector element is added BEFORE the promise is completed. Therefore, do not check if c == n but if the vector's size == n!\r\n\r\nMaybe we could use a threadsafe vector like in the C++ implementation and two atomic counters.\r\nRemove the unnecessary done variable.\r\nLook at: https://www.scala-lang.org/api/2.12.1/scala/collection/parallel/immutable/ParVector.html\r\nAnd for performance at: https://docs.scala-lang.org/overviews/collections/performance-characteristics.html"}}
{"actor":{"display_login":"tdauth"}}