{"action":"created","issue":{"url":"https://api.github.com/repos/rethinkdb/rethinkdb/issues/5771","repository_url":"https://api.github.com/repos/rethinkdb/rethinkdb","labels_url":"https://api.github.com/repos/rethinkdb/rethinkdb/issues/5771/labels{/name}","comments_url":"https://api.github.com/repos/rethinkdb/rethinkdb/issues/5771/comments","events_url":"https://api.github.com/repos/rethinkdb/rethinkdb/issues/5771/events","html_url":"https://github.com/rethinkdb/rethinkdb/issues/5771","id":155187190,"number":5771,"title":"Issues with `eachAsync` in JS driver.","user":{"login":"mlucy","id":1777134,"avatar_url":"https://avatars.githubusercontent.com/u/1777134?v=3","gravatar_id":"","url":"https://api.github.com/users/mlucy","html_url":"https://github.com/mlucy","followers_url":"https://api.github.com/users/mlucy/followers","following_url":"https://api.github.com/users/mlucy/following{/other_user}","gists_url":"https://api.github.com/users/mlucy/gists{/gist_id}","starred_url":"https://api.github.com/users/mlucy/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mlucy/subscriptions","organizations_url":"https://api.github.com/users/mlucy/orgs","repos_url":"https://api.github.com/users/mlucy/repos","events_url":"https://api.github.com/users/mlucy/events{/privacy}","received_events_url":"https://api.github.com/users/mlucy/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/rethinkdb/rethinkdb/labels/JavaScript%20/%20Coffee","name":"JavaScript / Coffee","color":"fef2c0"}],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":{"url":"https://api.github.com/repos/rethinkdb/rethinkdb/milestones/2","html_url":"https://github.com/rethinkdb/rethinkdb/milestones/backlog","labels_url":"https://api.github.com/repos/rethinkdb/rethinkdb/milestones/2/labels","id":211054,"number":2,"title":"backlog","description":"Issues in this milestone are not an immediate priority, and will be periodically revisited. When we decide to work on an issue in backlog, we'll move it to next.","creator":{"login":"coffeemug","id":48436,"avatar_url":"https://avatars.githubusercontent.com/u/48436?v=3","gravatar_id":"","url":"https://api.github.com/users/coffeemug","html_url":"https://github.com/coffeemug","followers_url":"https://api.github.com/users/coffeemug/followers","following_url":"https://api.github.com/users/coffeemug/following{/other_user}","gists_url":"https://api.github.com/users/coffeemug/gists{/gist_id}","starred_url":"https://api.github.com/users/coffeemug/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/coffeemug/subscriptions","organizations_url":"https://api.github.com/users/coffeemug/orgs","repos_url":"https://api.github.com/users/coffeemug/repos","events_url":"https://api.github.com/users/coffeemug/events{/privacy}","received_events_url":"https://api.github.com/users/coffeemug/received_events","type":"User","site_admin":false},"open_issues":869,"closed_issues":0,"state":"open","created_at":"2012-11-11T14:16:11Z","updated_at":"2016-07-20T00:38:10Z","due_on":null,"closed_at":null},"comments":10,"created_at":"2016-05-17T06:40:49Z","updated_at":"2016-07-22T01:01:09Z","closed_at":null,"body":"While using `eachAsync`, I ran into two places where the docs disagreed with the behavior:\r\n\r\n1. The docs say \"`eachAsync` always returns a promise that will be resolved once all rows are returned.\", but in fact `eachAsync` only returns a promise if the `final` callback is unspecified.\r\n\r\n2. The docs say \"If you do not use `rowFinished`, the `rowProcess` callback can end iteration early by returning any value other than a Promise; that value will be wrapped in an error object and passed to `final` if it is provided.\", but instead `final` seems to always receive the same error: \"Row handler for eachAsync may only return a Promise or undefined.\"\r\n\r\n(Note that I'm not really a JS user, so it's possible I'm misunderstanding something with regard to one or both of these.)\r\n\r\n@deontologician -- are these driver bugs or documentation bugs?"},"comment":{"url":"https://api.github.com/repos/rethinkdb/rethinkdb/issues/comments/234427824","html_url":"https://github.com/rethinkdb/rethinkdb/issues/5771#issuecomment-234427824","issue_url":"https://api.github.com/repos/rethinkdb/rethinkdb/issues/5771","id":234427824,"user":{"login":"cacois","id":347087,"avatar_url":"https://avatars.githubusercontent.com/u/347087?v=3","gravatar_id":"","url":"https://api.github.com/users/cacois","html_url":"https://github.com/cacois","followers_url":"https://api.github.com/users/cacois/followers","following_url":"https://api.github.com/users/cacois/following{/other_user}","gists_url":"https://api.github.com/users/cacois/gists{/gist_id}","starred_url":"https://api.github.com/users/cacois/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/cacois/subscriptions","organizations_url":"https://api.github.com/users/cacois/orgs","repos_url":"https://api.github.com/users/cacois/repos","events_url":"https://api.github.com/users/cacois/events{/privacy}","received_events_url":"https://api.github.com/users/cacois/received_events","type":"User","site_admin":false},"created_at":"2016-07-22T01:01:09Z","updated_at":"2016-07-22T01:01:09Z","body":"@marshall007 Not sure I follow - what does the Promise returned by run() resolve to?"}}
{"actor":{"display_login":"cacois"}}