fix(buzz): discover newly joined channels dynamically - #74823
Conversation
|
Tested the exact PR head Validation:
Live gateway test:
Result: the new membership subscription discovers and services a channel joined after startup. From this test lane, the change works as designed and is compatible with #74507. New channels are found “Right Here, Right Now.” |
|
Fresh integration verifier run on 2026-07-30. Tested the exact #74823 head
Live dynamic-channel discovery is green. The tests covered the intended remote-gateway path. |
|
Thanks for the focused Buzz fix. The current-main behavior matches the reported premise: startup uses unfiltered The PR's member-filtered snapshot and pre-snapshot membership cursor ( Automated hermes-sweeper review. |
|
I ran two additional live canaries on this PR's behavior and stacked lifecycle hardening directly on the exact PR head rather than opening a competing upstream PR: The follow-up covers malformed member snapshots, stale add/remove membership events, pre-join replay floors, reconnect reconciliation, leaving/pruning channels, polling fallback discovery, and forum-event isolation. Verification:
The branch is one commit on top of |
|
Correction to my hardening follow-up: an independent review found three blocking lifecycle race/replay paths in the current stacked commit. I have marked the follow-up as blocked and am adding deterministic regressions before asking anyone to merge it. The original #74823 result and live discovery proof are unaffected. |
Graph note (no action implied — a maintainer has already reviewed this thread). Our triage graph places this PR in a complex with 1 related pull request ( Full neighbourhood: https://hermes-triage.gottz.de/?node=74823 This note exists so the relationship stays discoverable from the thread itself. |
Signed-off-by: Reinhold <310554180+reinhold-ph@users.noreply.github.com>
e2e3797 to
b16e7a5
Compare
|
Superseded by #90802, which carries this behavior forward as part of the profile-scoped Buzz policy and Config integration on current |
What does this PR do?
Hermes currently snapshots Buzz channels at startup. When the Buzz identity joins or leaves an ordinary channel later, the running Gateway can miss the new channel indefinitely or retain a stale subscription until restart.
This refresh keeps automatic channel discovery synchronized for the lifetime of the Gateway while preserving explicitly configured channel restrictions.
When
channels/BUZZ_CHANNELSis absent or empty, the adapter now:REQ/CLOSEsends;When channels are explicitly configured, they remain a restrictive static watch set. Runtime membership events cannot broaden or remove them.
The Buzz user guide now documents both modes and the reconnect/replay behavior.
Related Issue
No linked issue. This replaces the stale/conflicting implementation already proposed in this PR; it is not a duplicate contribution.
Type of Change
Changes Made
plugins/platforms/buzz/adapter.pytests/gateway/test_buzz_adapter.pywebsite/docs/user-guide/messaging/buzz.mdHow to Test
uv run pytest -q tests/gateway/test_buzz_adapter.py tests/gateway/test_buzz_websocket.pyExpected: 50 passed.
uv run ruff check plugins/platforms/buzz/adapter.py tests/gateway/test_buzz_adapter.py tests/gateway/test_buzz_websocket.pyExpected: All checks passed.
python -m py_compile plugins/platforms/buzz/adapter.py tests/gateway/test_buzz_adapter.py tests/gateway/test_buzz_websocket.pyExpected: exit status 0.
uv sync --locked --python 3.11 --extra all --extra dev --extra anthropic --extra mistral --extra fal --extra modal --extra daytona --extra hindsight --extra parallel-weband then runs files in isolated subprocesses through
scripts/run_tests.sh. The two changed Buzz test files pass independently as reported above.git diff --check upstream/main..HEADExpected: no output and exit status 0.
Noncanonical monolithic-suite note
A single shared
pytest tests/process is not the repository's CI contract. It fails on pristine currentupstream/mainand this branch at the same first node after the same 706-test prefix:tests/agent/test_auxiliary_main_first.py::TestResolveVisionCustomProvider::test_custom_main_forwards_runtime_endpointThe node passes alone on both trees, proving an upstream order-dependent global-state leak. Current CI avoids this class intentionally by running each file in a fresh subprocess (
.github/workflows/tests.yml, lines 120-132). The lifecycle branch does not modify provider or auxiliary-client code.Checklist
Code
fix(scope):,feat(scope):, etc.)pytest tests/process and all tests pass — not checked: this is not canonical CI and current main reproduces the same order-dependent failure; changed test files pass in CI-style isolationDocumentation & Housekeeping
cli-config.yaml.example: N/A; no config keys were added or changedCONTRIBUTING.md/AGENTS.md: N/A; no contributor workflow changedScreenshots / Logs