You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Kanban auto-subscriptions could be stored with notifier_profile=NULL whenever gateway session metadata and HERMES_PROFILE were absent. In a multi-profile fleet, any gateway sharing the platform/chat could then claim and deliver that terminal event through the wrong bot.
When explicit session/environment ownership is unavailable, _maybe_auto_subscribe() now resolves the active Hermes profile through the canonical profile resolver before writing the subscription. Existing explicit ownership precedence is unchanged.
Thanks for the focused regression fix. The premise is confirmed on current main: tools/kanban_tools.py:1256-1267 can persist an ownerless subscription, while hermes_cli/kanban_db.py:8775-8779 writes that value directly. The added fallback preserves the existing explicit session/environment precedence and uses the canonical resolver at hermes_cli/profiles.py:1832-1856.
Sibling production writers already supply an owner: hermes_cli/kanban.py:2541-2545, gateway/slash_commands.py:504-510, and plugins/kanban/dashboard/plugin_api.py:1834-1841. The existing notifier regression at tests/gateway/test_kanban_notifier.py:240-294 verifies that a stamped owner cannot fall back to another profile's same-platform bot.
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
area/profilesMulti-profile isolation, HERMES_HOME scopingcomp/cronCron scheduler and job managementduplicateThis issue or pull request already existsP3Low — cosmetic, nice to havesweeper:blast-moderateSweeper blast radius: moderate — a subsystem or single platformsweeper:risk-message-deliverySweeper risk: may drop, duplicate, misroute, or suppress messagessweeper:risk-session-stateSweeper risk: may lose/corrupt/mis-associate session or context statetype/bugSomething isn't working
3 participants
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.
Summary
Fixes #57993.
Kanban auto-subscriptions could be stored with
notifier_profile=NULLwhenever gateway session metadata andHERMES_PROFILEwere absent. In a multi-profile fleet, any gateway sharing the platform/chat could then claim and deliver that terminal event through the wrong bot.When explicit session/environment ownership is unavailable,
_maybe_auto_subscribe()now resolves the active Hermes profile through the canonical profile resolver before writing the subscription. Existing explicit ownership precedence is unchanged.Tests
python -m pytest -q tests/tools/test_kanban_tools.py tests/hermes_cli/test_kanban_notify.py tests/gateway/test_kanban_notifier.pygit diff --check