Skip to content

Stop using channels APIs removed in v2 - #1492

Draft
llucax wants to merge 4 commits into
frequenz-floss:v1.x.xfrom
llucax:channels-1.13
Draft

llucax wants to merge 4 commits into
frequenz-floss:v1.x.xfrom
llucax:channels-1.13

Conversation

@llucax

@llucax llucax commented Nov 9, 2026

Copy link
Copy Markdown
Contributor

The SDK still uses channels APIs that v2 will remove. I switched to the stable WithPrevious import, MonotonicTimer, and calls to aclose() on channels without changing the SDK's public API or behavior. Broadcast and the SDK's new_receiver(limit=...) arguments stay unchanged.

This draft waits for frequenz-channels v1.13.0. The dependency commit temporarily points at channels PR 595 for testing. Before merging, I will update that commit to require frequenz-channels >= 1.13.0, < 2. The rest of the branch, including the release notes, already describes the released dependency. The typing-extensions floor is now 4.16.0, as channels requires.

Channels v1.13.0 has not been released yet. Use PR 595 to test the
SDK against its new APIs. Raise the typing-extensions floor to
4.16.0, which channels now requires. The SDK does not declare
frequenz-core directly; channels requires version 1.6.0 or later.

This reference is temporary until v1.13.0 is released. Replace it
with frequenz-channels >= 1.13.0, < 2 before publishing the SDK.

Signed-off-by: Leandro Lucarella <luca-frequenz@llucax.com>
Import WithPrevious from its stable module, use MonotonicTimer,
and call aclose() on channels. The promoted symbols are the same
objects and close() delegates to aclose(), so behavior stays the same.

Keep Broadcast and new_receiver(limit=...) unchanged. These APIs
remain available in channels v2, and moving to BroadcastChannel
would change behavior when there are no receivers.

Signed-off-by: Leandro Lucarella <luca-frequenz@llucax.com>
Explain the new dependency floors and the temporary PR reference
in the upgrading notes. The SDK's public API, timer behavior, and
channel closing do not change, so users do not need to change their code.

Signed-off-by: Leandro Lucarella <luca-frequenz@llucax.com>
This branch will merge only after channels v1.13.0 is released.
Describe the released dependency in the SDK release notes so that
only the dependency commit needs updating when the release is out.

Signed-off-by: Leandro Lucarella <luca-frequenz@llucax.com>
@github-actions github-actions Bot added part:docs Affects the documentation part:tests Affects the unit, integration and performance (benchmarks) tests part:tooling Affects the development tooling (CI, deployment, dependency management, etc.) part:data-pipeline Affects the data pipeline part:actor Affects an actor ot the actors utilities (decorator, etc.) part:core Affects the SDK core components (data structures, etc.) part:microgrid Affects the interactions with the microgrid part:config Affects the configuration management labels Nov 9, 2026

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

part:actor Affects an actor ot the actors utilities (decorator, etc.) part:config Affects the configuration management part:core Affects the SDK core components (data structures, etc.) part:data-pipeline Affects the data pipeline part:docs Affects the documentation part:microgrid Affects the interactions with the microgrid part:tests Affects the unit, integration and performance (benchmarks) tests part:tooling Affects the development tooling (CI, deployment, dependency management, etc.)

Projects

Status: To do

Development

Successfully merging this pull request may close these issues.

1 participant