Conversation
The `compose.py` and `select.py` examples in the actor module guide create `Broadcast` channels passing the name positionally, but `name` is a keyword-only argument in frequenz-channels v1, so the examples fail with a `TypeError`. These examples were never linted because their fences have a `title` option, which made the example linter skip them (frequenz-floss/frequenz-repo-config-python#652). Signed-off-by: Leandro Lucarella <luca-frequenz@llucax.com>
`select()` and `selected_from()` are now imported from `frequenz.channels` (`frequenz.channels.util` is gone), and `Selected` exposes the received message as `message` instead of `value`, so the example failed to import and, once fixed, raised an `AttributeError`. Signed-off-by: Leandro Lucarella <luca-frequenz@llucax.com>
The notes said both messages come from `input_channel_1`, but the second one comes from `input_channel_2`. The expected output was also missing the `EchoActor finished` line the actor prints when it stops. Signed-off-by: Leandro Lucarella <luca-frequenz@llucax.com>
llucax
marked this pull request as ready for review
October 5, 2026 16:50
llucax
requested review from
florian-wagner-frequenz
and removed request for
a team
October 5, 2026 16:50
llucax
enabled auto-merge
October 5, 2026 16:50
This branch has not been deployed
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
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.
The
compose.pyandselect.pyexamples in the actor module guide were written for the pre-v1 frequenz-channels API and fail when run:Broadcasttakesnameas a keyword-only argument,select()/selected_from()no longer live infrequenz.channels.util, andSelectedexposesmessageinstead ofvalue.They were never caught because their fences have a
titleoption, which makes the example linter skip the block entirely (frequenz-floss/frequenz-repo-config-python#652, fixed by frequenz-floss/frequenz-repo-config-python#653). Fixing them now means the repo-config bump that brings that fix won't break CI.Both examples now run and print the documented output.
Note: the
EchoActorexample at line 184 still fails the example linter until #1464 is merged.