Repository navigation
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Complete merge_each's next receiver when a nested sequence's sender fails or is stopped #2447
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
Uh oh!
There was an error while loading. Please reload this page.
Complete merge_each's next receiver when a nested sequence's sender fails or is stopped #2447
Changes from all commits
155e6c2File filter
Filter by extension
Conversations
Uh oh!
There was an error while loading. Please reload this page.
Jump to
Uh oh!
There was an error while loading. Please reload this page.
…ails or is stopped `merge_each` connects each item of the input sequence, which is a sender of a nested sequence, to `__receive_nested_sequence`. When that sender completed with `set_error` or `set_stopped`, or when subscribing to the nested sequence threw, the receiver only updated the bookkeeping of the `merge_each` operation and never completed the next receiver of the input sequence. The input sequence was left waiting for that item, so the `merge_each` operation never completed. For example, merge_each(just(1) | then([](int) -> decltype(just(0)) { throw 42; })) | ignore_all_values() never called its receiver, and a stop request that arrived between two nested sequences of `merge_each(iterate(...) | transform_each(...))` was lost in the same way. This diff completes the next receiver in those three places, as `__receive_nested_values` already does once a nested sequence has been subscribed. An error breaks the input sequence and is delivered as the last item, like the errors of nested sequences. A stopped sender is skipped, unless stop has been requested, in which case the input sequence is asked to stop too. The new tests cover an erroring sender, a stopped sender, a throwing `subscribe`, and a stop request between nested sequences. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com> Signed-off-by: Dezhen Lu <dezhen.lu@student.uni-tuebingen.de>Uh oh!
There was an error while loading. Please reload this page.
There are no files selected for viewing
Uh oh!
There was an error while loading. Please reload this page.