Skip to content
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

Check unsubscribe within observable from future #1291

Conversation

mattrjacobs
Copy link
Contributor

Right now, Observable.from(Future f) emits onError(CancellationException) when f starts out in a cancelled state. This change makes Observable.from(f) emit nothing in this case, and also when an unsubscribe occurs during a Future.get() that results in an Exception.

1) Creating an Observable from an already-cancelled Future should emit nothing (equivalent to Observable.never())
   (it currently emits onError(CancellationException)
2) Creating an Observable from a Future then unsubscribeing immediately before Future.get()
   unblocks should be an Observable.never().  This test already passes.
@cloudbees-pull-request-builder

RxJava-pull-requests #1190 SUCCESS
This pull request looks good

benjchristensen added a commit that referenced this pull request May 30, 2014
…servable-from-future

Check unsubscribe within observable from future
@benjchristensen benjchristensen merged commit d3a2f68 into ReactiveX:master May 30, 2014
This was referenced May 30, 2014
@mattrjacobs mattrjacobs deleted the check-unsubscribe-within-observable-from-future branch January 8, 2015 06:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants