We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
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
Looks like finallyDo is behaving wrong:
finallyDo
package rx.lang.groovy.examples import rx.Observable class Testing { static class myActionClass implements rx.util.functions.Action0 { void call() { println('Finally'); } } static main(args) { def myAction = new myActionClass(); def numbers = Observable.toObservable([1, 2, 3, 4, 5]); numbers.finallyDo(myAction).subscribe( [ onNext: { println(it); }, onCompleted:{ println("Sequence complete"); }, onError:{ println("Error encountered"); } ] ); } }
Output: 1 2 3 4 5 Sequence complete Finally
I believe "Finally" should happen before "Sequence Completed"
The text was updated successfully, but these errors were encountered:
This issues was raised when finally PR was being sent. #196 (comment)
finally
Here is the C# equivalent code I just checked with.
using System; using System.Reactive.Linq; var members = new[] { 1, 2, 3, 4, 5 }.ToObservable(); members .Finally(() => Console.WriteLine("Finally")) .Subscribe(Console.WriteLine /* next */, Console.WriteLine /* exception */, () => Console.WriteLine("Sequence Completed"));
Output:
1 2 3 4 5 Sequence Completed Finally
Current behavior is correct.
Sorry, something went wrong.
Great. Thank you for confirming with C# code.
No branches or pull requests
Looks like
finallyDo
is behaving wrong:I believe "Finally" should happen before "Sequence Completed"
The text was updated successfully, but these errors were encountered: