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

MessageFeed.latest_update for simple race-free waits #131

Merged
merged 1 commit into from
Nov 20, 2024

Conversation

mhidalgo-bdai
Copy link
Contributor

MessageFeed.latest yields what's available in buffers and MessageFeed.update can be used to wait for what comes next, but neither helps the common wait-for-a-message use case. This is particularly bad for message feeds tied to transient local ROS 2 topic subscriptions, as both race with a single message dispatch.

Thus, this patch adds MessageFeed.latest_update to cover for this.

@mhidalgo-bdai mhidalgo-bdai merged commit e4d5c80 into main Nov 20, 2024
4 checks passed
@mhidalgo-bdai mhidalgo-bdai deleted the mhidalgo-bdai/race-free-latest-message-waits branch November 20, 2024 18:13
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.

3 participants