-
Notifications
You must be signed in to change notification settings - Fork 1.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
changes / replicate should return a complete promise? #1521
Comments
+10000 |
Im gonna say this is a reasonably clear patch, goodfirstpatching |
A note to the fixer that you can't just use toPromise and you have to deal
|
Looking at this I see that Cancellation/A+, which bluebird seems to be following, suggests cancellation should reject a promise rather than resolve it. Recent changes to PouchDB make cancellation of changes more reliable, but with no error to the callback. Perhaps now, as complete promises are being introduced, this should be revisited and cancellation should return an error to callbacks and rejection of the promise. I am working on a change to changes in adapter.js to return a complete promise and, at the moment to return an error on cancellation, but it is easy enough to go either way with the return. Might a change to returning an error/rejection on cancel be accepted? |
I think the main focus should be on making it a readable stream first, and then promise second, there is no reason it can't be both but a stream is going to be the more natural way to get data, the main hurdle there is going to be pausing the stream which is currently impossible to do. |
this is done |
No description provided.
The text was updated successfully, but these errors were encountered: