hermes - 💡(How to fix) Fix v0.5.1 Desktop App: Session continuation error, api_key lost, duplicate replies

Official PRs (…)
ON THIS PAGE

Recommended Tools

×6

Utilities matched from this issue’s tags and category — try them while you read without losing context.

GitHub issue graph ai analysis

Paste a GitHub issue URL. We fetch that issue, discover linked issues from bodies/comments/timeline, collect linked pull requests, and produce a structured English report.

The report is written in English Markdown for sharing and archival.

Helpful · Quick feedback

Loading…

After the API_SERVER_KEY error occurs, the desktop app sometimes sends duplicate replies (same content appears twice).

Error Message

Error: Session continuation requires API key authentication. Configure API_SERVER_KEY to enable this feature.

Root Cause

Root Cause (Suspected)

v0.5.1 enables session continuation by default for desktop app, but the Electron app doesn't read API_SERVER_KEY from launchctl setenv or config.yaml agent.env.

Fix Action

Workaround

Manually re-add api_key: <key> under model: section and restart gateway.


Code Example

Error: Session continuation requires API key authentication. Configure API_SERVER_KEY to enable this feature.
RAW_BUFFERClick to expand / collapse

Bug Report: Multiple Issues in Hermes Agent v0.5.1 Desktop App

Environment

  • Version: v0.5.1 (upgraded from v0.3)
  • Platform: macOS (Desktop App - Electron)
  • WeChat integration: Works fine
  • Desktop App: Has multiple issues

Issue 1: Desktop App Session Continuation Fails with API_SERVER_KEY Error

Description

After upgrading from v0.3 to v0.5.1, the desktop app fails with:

Error: Session continuation requires API key authentication. Configure API_SERVER_KEY to enable this feature.

Steps to Reproduce

  1. Upgrade from v0.3 to v0.5.1
  2. Open Hermes Agent desktop app
  3. Send a message
  4. App replies, then immediately throws the error

Workaround

Set api_server: enabled: false in ~/.hermes/config.yaml

Root Cause (Suspected)

v0.5.1 enables session continuation by default for desktop app, but the Electron app doesn't read API_SERVER_KEY from launchctl setenv or config.yaml agent.env.


Issue 2: model.api_key Field Gets Lost from config.yaml

Description

The api_key field under model: section in ~/.hermes/config.yaml gets randomly removed or lost after agent restarts or config reloads.

Impact

Agent fails with 401 Authentication Error because no API key is sent.

Workaround

Manually re-add api_key: <key> under model: section and restart gateway.


Issue 3: MiniMax API Endpoint Confusion

Description

The correct OpenAI-compatible endpoint for MiniMax is:

  • https://api.minimax.chat/v1/chat/completions
  • https://api.minimax.io/v1/chat/completions (returns 401)

This is not documented clearly. Users (and AI agents) may use the wrong endpoint.


Issue 4: Desktop App Duplicate Replies

Description

After the API_SERVER_KEY error occurs, the desktop app sometimes sends duplicate replies (same content appears twice).

Steps to Reproduce

  1. Trigger the API_SERVER_KEY error
  2. Continue chatting
  3. Some replies appear duplicated

Additional Context

  • WeChat channel works perfectly throughout all these issues
  • Desktop app (Electron) and WeChat share the same config.yaml
  • The issues seem specific to the desktop app's session management in v0.5.1

Expected Behavior

  • Desktop app should either:
    1. Not require API_SERVER_KEY for normal session usage, OR
    2. clearly document how to set it for Electron apps (Finder-launched)
  • model.api_key should not be lost after config reloads
  • MiniMax endpoint should be documented or auto-detected

Vote matrix · Quick signals

Works
Did the solution work? Tap to confirm.
Easy Fix
Was it a quick fix?
Time Saver
Did it save you time?
Blocking
Was it severely blocking?
Common Issue
Are others likely hitting this too?
Flaky / Intermittent
Is it intermittent?
Verified / Reproducible
Can you reproduce it reliably?
Loading…

Still need to ship something?

×6

Another batch ranked right after the header list — different links, same matching logic.

Back to top recommendations

TRENDING

hermes - 💡(How to fix) Fix v0.5.1 Desktop App: Session continuation error, api_key lost, duplicate replies