Skip to content

Prepare dispatch for channels v2 - #324

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

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

Conversation

@llucax

@llucax llucax commented Nov 9, 2026

Copy link
Copy Markdown
Contributor

Dispatch still uses the Timer alias and channel close method that channels v2 removes. I replace them with MonotonicTimer and aclose without changing the public dispatch API or behavior.

The frequenz-channels dependency points at PR 595 temporarily until v1.13.0 is released. After the release, the dependency will change to >= 1.13.0, < 2. I raise the core and typing-extensions floors to the versions channels requires so pytest_min can resolve them.

The scheduler needs MonotonicTimer, which is new in channels v1.13.0.
Point the dependency at PR 595 temporarily until v1.13.0 is released,
then replace it with >= 1.13.0, < 2.

Raise the core floor to 1.6.0 and typing-extensions to 4.16.0, which
channels v1.13 requires. Users get these versions through channels
anyway, so this adds no new constraint. It lets pytest_min resolve the
same requirements when it pins the direct dependency floors.

Signed-off-by: Leandro Lucarella <luca-frequenz@llucax.com>
Use MonotonicTimer for the retry and scheduling timers, including the
private annotations. Replace the actor channel's close call with
aclose. These replacements keep the existing timing and shutdown
behavior while avoiding APIs removed in channels v2.

Signed-off-by: Leandro Lucarella <luca-frequenz@llucax.com>
Document the temporary channels reference and its required core and
typing-extensions versions. The channels API migration only changes
internal code, so users don't need to change their dispatch calls.

Signed-off-by: Leandro Lucarella <luca-frequenz@llucax.com>
@github-actions github-actions Bot added part:docs Affects the documentation part:tooling Affects the development tooling (CI, deployment, dependency management, etc.) part:dispatcher Affects the high-level dispatcher interface 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:dispatcher Affects the high-level dispatcher interface part:docs Affects the documentation part:tooling Affects the development tooling (CI, deployment, dependency management, etc.)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant