mirror of
https://github.com/NousResearch/hermes-agent.git
synced 2026-07-20 15:33:54 +00:00
fix(agent): register Upstage keys in the env-var catalog
`UPSTAGE_API_KEY` / `UPSTAGE_BASE_URL` were wired through the provider resolver, auth registry, and the EnvPage grouping, but never added to `OPTIONAL_ENV_VARS` in hermes_cli/config.py. The dashboard/desktop Providers page builds its list from that catalog (`/api/env` iterates `OPTIONAL_ENV_VARS`), so with no entry the keys were never emitted and "Upstage Solar" never rendered — the EnvPage prefix group stayed empty. Add both keys under `category: "provider"` (matching gmi/minimax) so they show up in `hermes dashboard` / `hermes desktop` under "Upstage Solar". Adds a regression test asserting the catalog contains them, mirroring the existing GMI coverage. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
parent
0031c5c371
commit
c1e36f4329
2 changed files with 35 additions and 0 deletions
|
|
@ -68,6 +68,26 @@ class TestUpstageOverlay:
|
|||
assert get_label("upstage") == "Upstage Solar"
|
||||
|
||||
|
||||
class TestUpstageEnvCatalog:
|
||||
"""The dashboard/desktop Providers page lists only OPTIONAL_ENV_VARS keys
|
||||
whose category is "provider". Without these entries UPSTAGE_API_KEY /
|
||||
UPSTAGE_BASE_URL never reach the frontend and Upstage stays invisible even
|
||||
though EnvPage.tsx has a matching PROVIDER_GROUPS prefix.
|
||||
"""
|
||||
|
||||
def test_optional_env_vars_include_upstage(self):
|
||||
from hermes_cli.config import OPTIONAL_ENV_VARS
|
||||
|
||||
assert "UPSTAGE_API_KEY" in OPTIONAL_ENV_VARS
|
||||
assert OPTIONAL_ENV_VARS["UPSTAGE_API_KEY"]["category"] == "provider"
|
||||
assert OPTIONAL_ENV_VARS["UPSTAGE_API_KEY"]["password"] is True
|
||||
assert OPTIONAL_ENV_VARS["UPSTAGE_API_KEY"]["url"]
|
||||
|
||||
assert "UPSTAGE_BASE_URL" in OPTIONAL_ENV_VARS
|
||||
assert OPTIONAL_ENV_VARS["UPSTAGE_BASE_URL"]["category"] == "provider"
|
||||
assert OPTIONAL_ENV_VARS["UPSTAGE_BASE_URL"]["password"] is False
|
||||
|
||||
|
||||
class TestUpstageConfigProviderWins:
|
||||
"""End-to-end: an explicit config provider must beat env auto-detect.
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue