-
Notifications
You must be signed in to change notification settings - Fork 6
fix: Pubsub typing #1153
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
Merged
Merged
fix: Pubsub typing #1153
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Greptile OverviewGreptile SummaryThis PR aligns Key changes:
The changes are safe because:
Confidence Score: 5/5
Important Files Changed
Sequence DiagramsequenceDiagram
participant Client
participant LCMPubSubBase
participant LCM
participant Callback
Client->>LCMPubSubBase: subscribe(topic: Topic, callback)
alt topic.is_pattern
LCMPubSubBase->>LCMPubSubBase: Create pattern handler
LCMPubSubBase->>LCM: subscribe(pattern_str, handler)
LCM-->>LCMPubSubBase: lcm_subscription
Note over LCMPubSubBase: handler calls callback with<br/>Topic.from_channel_str(channel)
else regular topic
LCMPubSubBase->>LCM: subscribe(topic_str, lambda)
LCM-->>LCMPubSubBase: lcm_subscription
Note over LCMPubSubBase: lambda calls callback with<br/>original Topic object
end
LCMPubSubBase->>LCMPubSubBase: Set queue capacity to 10000
LCMPubSubBase-->>Client: unsubscribe function
Note over LCM,Callback: When message arrives
LCM->>Callback: callback(msg: bytes, topic: Topic)
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
1 file reviewed, no comments
- LCMCommsConfig now uses LCMTopic with default_factory - Add proper type params to PubSubComms and LCMSkillComms - Fix SkillMsg type annotations with MsgType param - Add explicit re-exports in protocol/service/__init__.py - Wrap string topic in LCMTopic in pLCMTransport
- Add subscribe method declaration to mixin - Fix _Subscription type to use PubSubBaseMixin
paul-nechifor
approved these changes
Jan 29, 2026
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
addresses comments from #1114
Removes type: ignore[override] by changing subscribe signature to match the AllPubSub[Topic, Any] base class contract.