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

DOM: Implement finally() Observable operator #50885

Merged
merged 1 commit into from
Feb 21, 2025

Conversation

chromium-wpt-export-bot
Copy link
Collaborator

@chromium-wpt-export-bot chromium-wpt-export-bot commented Feb 21, 2025

See WICG/observable#153. This CL implements the
finally() operator. It registers a callback which runs on both
producer-initiated and consumer-initiated unsubscription. Its
implementation is relatively straightforward, just utilizing the
relevant subscriber's teardown list.

This CL used to be really complicated, as was the spec PR. This has all
been simplified since the factors that made it complicated (and broken)
have been landed. See:

Now that the simplifying factors have been landed, this CL can proceed
with a simple implementation, which passes all of the tests.

R=[email protected]

Bug: 40282760
Change-Id: Ifff220ec094abd2187f35020eae85c1bca502f89
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/5654720
Reviewed-by: Di Zhang <[email protected]>
Commit-Queue: Dominic Farolino <[email protected]>
Cr-Commit-Position: refs/heads/main@{#1423349}

See WICG/observable#153. This CL implements the
`finally()` operator. It registers a callback which runs on both
producer-initiated and consumer-initiated unsubscription. Its
implementation is relatively straightforward, just utilizing the
relevant subscriber's teardown list.

This CL used to be really complicated, as was the spec PR. This has all
been simplified since the factors that made it complicated (and broken)
have been landed. See:
 - WICG/observable#151 (comment)
 - WICG/observable#154
 - https://crrev.com/c/5676226

Now that the simplifying factors have been landed, this CL can proceed
with a simple implementation, which passes all of the tests.

[email protected]

Bug: 40282760
Change-Id: Ifff220ec094abd2187f35020eae85c1bca502f89
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/5654720
Reviewed-by: Di Zhang <[email protected]>
Commit-Queue: Dominic Farolino <[email protected]>
Cr-Commit-Position: refs/heads/main@{#1423349}
Copy link
Collaborator

@wpt-pr-bot wpt-pr-bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The review process for this patch is being conducted in the Chromium project.

@chromium-wpt-export-bot chromium-wpt-export-bot merged commit 12acca9 into master Feb 21, 2025
15 checks passed
@chromium-wpt-export-bot chromium-wpt-export-bot deleted the chromium-export-cl-5654720 branch February 21, 2025 21:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants