Skip to content

fix(kanban): notify tool-created tasks - #25195

Closed
eloklam wants to merge 2 commits into
NousResearch:mainfrom
eloklam:fix/kanban-tool-created-task-notifications
Closed

eloklam wants to merge 2 commits into
NousResearch:mainfrom
eloklam:fix/kanban-tool-created-task-notifications

Conversation

@eloklam

@eloklam eloklam commented May 13, 2026

Copy link
Copy Markdown
Contributor

Summary

Kanban tasks created through the tool path could finish or block silently because they never received gateway notification subscriptions.

Slash-command-created tasks already call add_notify_sub(...), but orchestrator/worker fan-out goes through tools/kanban_tools.py::_handle_create, which previously only created the task row. That left kanban_notify_subs empty, so the gateway notifier had no destination when the task reached a terminal state.

This PR adds notification setup to tool-created tasks and preserves subscriptions across child-task fan-out.

Changes

  • Add _ensure_notify_subscriptions(...) in tools/kanban_tools.py.
  • Copy existing parent kanban_notify_subs rows onto newly created child tasks.
  • If no parent subscription exists, read the active gateway session via gateway.session_context.get_session_env(...) and subscribe the origin platform/chat/thread.
  • Lazy-import gateway session context so normal CLI/test imports stay safe.
  • Preserve CLI/no-session behavior: if no gateway session is present, no subscription is created.
  • Add regression tests for origin chat auto-subscription, child task inheritance, and no phantom subscriptions without parent/session context.
  • Add AUTHOR_MAP entry for contributor attribution check (scripts/release.py).

Validation

  • scripts/run_tests.sh tests/tools/test_kanban_tools.py::test_create_auto_subscribes_origin_in_gateway_session tests/tools/test_kanban_tools.py::test_create_child_inherits_parent_notify_subscriptions tests/tools/test_kanban_tools.py::test_create_no_subscription_without_parent_or_session tests/hermes_cli/test_kanban_notify.py -q
    • 13 passed in 12.56s

Notes

  • No linked issue.
  • No schema migration; this reuses the existing kanban_notify_subs table and notifier flow.

@alt-glitch alt-glitch added type/bug Something isn't working P3 Low — cosmetic, nice to have comp/tools Tool registry, model_tools, toolsets labels May 13, 2026
@alt-glitch

Copy link
Copy Markdown
Contributor

Related to #21523, #24307 (duplicate of merged-then-reverted #19718/#19721), and tracking issue #19479. The merge/revert cycle on #19718 left this gap unfixed.

@eloklam

eloklam commented May 14, 2026

Copy link
Copy Markdown
Contributor Author

Related to #21523, #24307 (duplicate of merged-then-reverted #19718/#19721), and tracking issue #19479. The merge/revert cycle on #19718 left this gap unfixed.

Aint no way this is P3 bro

@teknium1

Copy link
Copy Markdown
Collaborator

Merged via PR #28433 (cherry-picked onto current main with your authorship preserved via rebase-merge — commit 9d9f316). Thanks for the contribution!

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

Labels

comp/tools Tool registry, model_tools, toolsets P3 Low — cosmetic, nice to have type/bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants