Skip to content

Conversation

@Marenz
Copy link
Contributor

@Marenz Marenz commented Jan 8, 2025

This way we can always send a status update to a new receiver

This way we can always send a status update to a new receiver

Signed-off-by: Mathias L. Baumann <[email protected]>
@github-actions github-actions bot added the part:dispatcher Affects the high-level dispatcher interface label Jan 8, 2025
dispatch_type: str,
running_status_receiver: Receiver[Dispatch],
updates_sender: Sender[DispatchUpdate] | None = None,
actor: Actor | Set[Actor] | None = None,
Copy link
Contributor

Choose a reason for hiding this comment

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

I was going for an actor factory. Will submit my WIP as a draft PR so maybe you can get some inspiration about it, or we can discuss pros and cons from the different approaches.

Comment on lines +138 to +144
def new_receiver(self) -> Receiver[DispatchUpdate]:
"""Create a new receiver for dispatch updates.
Returns:
A new receiver for dispatch updates.
"""
return self._updates_channel.new_receiver()
Copy link
Contributor

Choose a reason for hiding this comment

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

Oh, yes! I also thought about this, but I didn't start to address this but was my next step. I think this actor should also stop being an actor and just be a background service.

I'm not sure it is needed with my approach, but I think it would be convenient anyway, I see no advantages in delegating the creation of the channel to the outside.

@llucax
Copy link
Contributor

llucax commented Jan 8, 2025

@Marenz
Copy link
Contributor Author

Marenz commented Jan 27, 2025

replaced by #103

@Marenz Marenz closed this Jan 27, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

part:dispatcher Affects the high-level dispatcher interface

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants