Skip to content

fix: resolve Homebrew gt path and prevent activity-feed ENOENT crash#26

Merged
web3dev1337 merged 1 commit intomasterfrom
fix/issue-25-gt-path
Mar 27, 2026
Merged

fix: resolve Homebrew gt path and prevent activity-feed ENOENT crash#26
web3dev1337 merged 1 commit intomasterfrom
fix/issue-25-gt-path

Conversation

@web3dev1337
Copy link
Copy Markdown
Owner

Summary

Fixes issue #25 where GUI crashes on startup/websocket connect when gt is not on PATH (common with Homebrew installs at /opt/homebrew/bin/gt).

Root cause:

  • Multiple backend paths hardcoded gt/bd command names.
  • Activity feed subprocess had no error listener, so spawn gt ENOENT crashed Node.

Changes:

  • Added ExecutableResolver to resolve binaries from:
    • explicit env overrides: GT_BIN, BD_BIN
    • PATH
    • fallback paths including /opt/homebrew/bin/*, /usr/local/bin/*, Linuxbrew
  • Wired resolved executables through:
    • server.js executeGT/executeBD
    • onboarding setup version checks
    • websocket activity feed spawn path
    • GTGateway and BDGateway via injectable executable
  • Hardened activity feed lifecycle:
    • added process error handler
    • restart scheduling deduplication
    • timer cleanup when last websocket client disconnects
  • Added docs for new env vars and infrastructure.

Tests

Baseline before changes:

  • npm test (passed on origin/master)

After changes:

  • npm test -- test/unit/executableResolver.test.js test/integration/cli-executable-resolution.test.js test/unit/gtGateway.test.js test/unit/bdGateway.test.js
  • npm test
  • npm run test:e2e

All passing.

Issue Link

Closes #25

@web3dev1337 web3dev1337 merged commit ca37668 into master Mar 27, 2026
5 checks passed
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.

can't find gt when using a homebrew installation

1 participant