Skip to content

Conversation

@llucax
Copy link
Contributor

@llucax llucax commented Nov 22, 2023

We need to make Merge public again, because the Merge receiver has more methods than a plain Receiver, in particular stop(), which users need to use for guaranteed cleanup.

But in this case it is better to introduce a breaking change to make sure users update to using the new merge() function, so we rename it to Merger. Also using a noun for the name is more in line with the other classes.

This also means now the merge() function returns the Merger instance instead of an abstract Receiver.

Additionally there are a couple of small unrelated cleanups:

  • Remove darglint-related stuff, it was replaced by pydoclint a while ago.
  • Remove cookiecutter template TODO comment.

`darglint` was replaced by `pydoclint` a while ago, so we don't need
this stuff anymore.

Signed-off-by: Leandro Lucarella <[email protected]>
@llucax llucax requested a review from a team as a code owner November 22, 2023 12:58
@llucax llucax self-assigned this Nov 22, 2023
@github-actions github-actions bot added part:docs Affects the documentation part:tests Affects the unit, integration and performance (benchmarks) tests part:core Affects the core types (`Sender`, `Receiver`, exceptions, etc.) labels Nov 22, 2023
@llucax llucax requested a review from shsms November 22, 2023 12:58
@llucax llucax added this to the v1.0.0 milestone Nov 22, 2023
@llucax llucax added the type:enhancement New feature or enhancement visitble to users label Nov 22, 2023
The `Merge` receiver was made private to try to hide the implementation
details to the user, but it was a bad idea because the `Merge` receiver
has more methods than a plain `Receiver`, in particular `stop()`, which
users need to use for guaranteed cleanup.

This also means now the `merge()` function returns the `Merge` instance
instead of an abstract `Receiver`.

Signed-off-by: Leandro Lucarella <[email protected]>
Signed-off-by: Leandro Lucarella <[email protected]>
@llucax
Copy link
Contributor Author

llucax commented Nov 22, 2023

Enabling auto-merge

Copy link
Contributor

@daniel-zullo-frequenz daniel-zullo-frequenz left a comment

Choose a reason for hiding this comment

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

I only have a question and LGTM otherwise

@llucax
Copy link
Contributor Author

llucax commented Dec 1, 2023

@shsms last opportunity to complain, if @daniel-zullo-frequenz approves I will merge if you didn't complain before 😆

@llucax llucax added this pull request to the merge queue Dec 4, 2023
Merged via the queue into frequenz-floss:v1.x.x with commit 8e624b4 Dec 4, 2023
@llucax llucax deleted the merger branch December 4, 2023 13:33
@llucax llucax modified the milestones: v1.0.0, v1.0.0-rc.1 Mar 7, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

part:core Affects the core types (`Sender`, `Receiver`, exceptions, etc.) part:docs Affects the documentation part:tests Affects the unit, integration and performance (benchmarks) tests type:enhancement New feature or enhancement visitble to users

Projects

Development

Successfully merging this pull request may close these issues.

2 participants