feat(kanban): gate notifier watcher on dispatch_in_gateway#37174
Merged
Conversation
Non-dispatch gateways no longer open per-board kanban DBs for notifier polling. Mirrors the existing dispatcher gate (config kanban.dispatch_in_gateway, default True; env override HERMES_KANBAN_DISPATCH_IN_GATEWAY) so multi-gateway setups collapse to a single process holding kanban.db file descriptors. Salvaged from PR #31964 by @steveonjava; tests and docs trimmed during salvage.
3 tasks
Contributor
🔎 Lint report:
|
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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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
The
/modelpicker no longer silently routes an OpenAI selection to OpenRouter. Users with a configured OpenAI provider (and no OpenRouter key) now stay onapi.openai.cominstead of hitting HTTP 401 "Missing Authentication header."Root cause:
hermes_cli/providers.pycarries a legacy alias"openai" → "openrouter". The picker emitted a standaloneslug="openai"row (gated onOPENAI_API_KEY); selecting it ranresolve_provider_full("openai"), which resolved that built-in alias to OpenRouter before checking the user's ownproviders.openaiconfig.Changes
model_switch.list_authenticated_providers: skip vendor names that are aliases to an aggregator (isolates exactlyopenai→openrouter;copilot/kimi/etc. are real providers and unaffected). Kills the phantom picker row.providers.resolve_provider_full: user-configproviders.<name>now resolves before the built-in alias table, soproviders.openai(api.openai.com) beats the legacy alias.model_switchPATH A: user-config providers resolve credentials via their own endpoint instead of the name-based runtime resolver that doesn't know user-config slugs; plus a fail-loud guard for explicit unauthed-aggregator hops.Validation
target=openrouterbase=openrouter.ai → 401target=openaibase=api.openai.com ✓--provider openai-apiTargeted suites green (model_switch / providers / inventory / runtime / auth — 384 + 224 + 295 passing). Added 3 regression tests; converted 1 test that codified the phantom-row behavior.
Scope
Independent of #35056 (which doesn't touch the picker) and #24234 (separate encrypted-content 400). Does not change the
OPENAI_API_KEY-implies-openrouter overlay (issue #6799) — that's a wider resolution-semantics change #35056 rewrites; the reported symptom is fixed without it.Related issues: #14057 (duplicate OpenAI/openai picker rows), #19858 (model switcher hops to OpenRouter).
Infographic
Infographic
Infographic