hermes - 💡(How to fix) Fix Config migration is profile-local; non-active profiles silently drift across Hermes upgrades [1 participants]

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…
GitHub stats
NousResearch/hermes-agent#20438Fetched 2026-05-06 06:36:49
View on GitHub
Comments
0
Participants
1
Timeline
4
Reactions
0
Author
Participants
Timeline (top)
labeled ×4
RAW_BUFFERClick to expand / collapse

When hermes update (or hermes setup) bumps _config_version and seeds new defaults, the migration only runs against the currently active HERMES_HOME. Other profiles under ~/.hermes/profiles/*/ (or custom-rooted profiles) keep their old _config_version and old on-disk shape until the user happens to activate them and re-run setup.

This is a real drift surface, not theoretical. Today after upgrading to v23 (curator defaults seeding), I ended up with three profiles in three different states:

  • the active profile: v23, with curator: and auxiliary.curator: written to disk
  • a sibling profile: v22, with a legacy curator.auxiliary block that v23 has retired
  • another sibling: v22, missing curator.backup and auxiliary.curator entirely

In all three, the runtime load_config() deep-merge papers over the gap — the curator runs — but:

  1. Users can't see or edit the active settings in their config.yaml
  2. _config_version on disk lies about the schema actually in use
  3. A future v23→v24 migration that depends on v23-shaped data finds v22-shaped data and either silently no-ops on conditions that already match defaults, or fires repair logic that's expensive/wrong

Proposal (cheapest first):

  1. Migrate-on-activation (preferred). When hermes -p X ... activates a profile whose _config_version is below DEFAULT_CONFIG["_config_version"], run the migration silently (or with a one-line "migrating profile X to v<N>" notice) before the agent starts.

  2. Walk-all-profiles in hermes update. Iterate the configured profile roots and migrate each. Belt-and-suspenders on (1) for users who don't activate every profile.

I'd argue against persisting the deep-merge result to disk on every load — it breaks the "absent key inherits default forever" contract and would surprise users who deliberately leave keys unset to follow upstream.

Happy to put up a PR for (1) if it's wanted.

extent analysis

TL;DR

Migrate profiles to the latest version when activated or during hermes update to prevent configuration drift.

Guidance

  • Implement "Migrate-on-activation" to run the migration silently when a profile is activated with an outdated _config_version.
  • Consider "Walk-all-profiles in hermes update" as a fallback to migrate all profiles during the update process.
  • Verify the migration by checking the _config_version and configuration settings in each profile after activation or update.
  • Test the migration process to ensure it handles different profile states and versions correctly.

Example

No code snippet is provided as it is not explicitly supported by the issue.

Notes

The proposed solutions aim to address the configuration drift issue, but the implementation details and potential edge cases need to be considered.

Recommendation

Apply the "Migrate-on-activation" workaround to ensure profiles are migrated to the latest version when activated, as it is the preferred solution.

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