Skip to content

fix(integrations): run the bm and uv that PATH names in Hermes - #2110

Merged
phernandez merged 1 commit into
mainfrom
fix/1783-hermes-path-binary
Nov 13, 2026
Merged

phernandez merged 1 commit into
mainfrom
fix/1783-hermes-path-binary

Conversation

@phernandez

Copy link
Copy Markdown
Member

Fixes #1783.

#1783 reported two problems in the Hermes provider.

  1. Config path ignored XDG_CONFIG_HOME. Already fixed under Hermes provider rejects Basic Memory 1.0 projects absent from legacy config.json registry #2019. The provider no longer reads Basic Memory's config file; it lists projects through bm_project_list on the bm mcp child, which resolves its own config directory.
  2. Binary lookup order. _bm_binary_path() and _uv_binary_path() tried ~/.local/bin, /opt/homebrew/bin and /usr/local/bin before PATH. A stale uv-tool bm in ~/.local/bin therefore ran instead of the bm the user's shell runs. This PR fixes that.

Change

One _find_binary(name, search_path=None) helper serves both lookups. It searches PATH first and falls back to the fixed locations only when PATH has no match. The fallback is still needed for a gateway under launchd, whose PATH is the minimal system default.

Tests

  • test_find_binary_prefers_the_path_match: a bm on the given PATH is returned even though ~/.local/bin/bm may exist.
  • test_find_binary_skips_a_non_executable_path_entry: a non-executable file on PATH is not returned.
  • just package-check-hermes passes (367 passed).

🤖 Generated with Claude Code

https://claude.ai/code/session_01CMYVL1rjJwNnrvxniz1dDD

The Hermes provider tried ~/.local/bin, /opt/homebrew/bin and
/usr/local/bin before PATH, so a stale uv-tool bm shadowed the one the
user's shell runs. Search PATH first and keep the fixed locations as the
fallback for launchd-style minimal PATHs.

Fixes #1783

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01CMYVL1rjJwNnrvxniz1dDD
Signed-off-by: phernandez <paul@basicmachines.co>
@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Nov 12, 2026 •

Copy link
Copy Markdown
Codex Review Summary: ✅ Completed

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-11-12T21:24:42.964324Z d7569d3 PR opened
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@phernandez
phernandez merged commit b80ec71 into main Nov 13, 2026
25 checks passed
@phernandez
phernandez deleted the fix/1783-hermes-path-binary branch November 13, 2026 01:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Hermes integration reads bm's project registry from ~/.basic-memory even when XDG_CONFIG_HOME is set

1 participant