-
Notifications
You must be signed in to change notification settings - Fork 185
Description
Summary
The hindsight-api command defaults to port 8888 when run directly (non-daemon mode), but the entire hindsight-embed ecosystem, including daemon_client.py, the OpenClaw plugin (embed-manager.ts), and the control plane UI, all expect port 8889. This causes connection refused errors when users try to run the daemon manually or troubleshoot outside of --daemon mode.
Details
The port configuration is inconsistent across the codebase:
hindsight-api/hindsight_api/config.py:DEFAULT_PORT = 8888(used byhindsight-apiCLI)hindsight-api/hindsight_api/daemon.py:DEFAULT_DAEMON_PORT = 8889(used when--daemonflag is passed)hindsight-embed/hindsight_embed/daemon_client.py:DAEMON_PORT = 8889(hardcoded)hindsight-integrations/openclaw/src/embed-manager.ts:this.port = 8889(hardcoded)
When running hindsight-api --daemon, the port is overridden to 8889 in main.py. But when running hindsight-api directly (for manual testing, troubleshooting, or development), it defaults to 8888. All consumers of the API assume port 8889, so the non-daemon default of 8888 is surprising and causes connection failures.
Steps to Reproduce
- Run
hindsight-api(without--daemon) - Observe it binds to port 8888
- Try to use
hindsight-embedcommands that call the daemon client - Get connection refused on port 8889
Expected Behavior
DEFAULT_PORT in config.py should be 8889 to match the rest of the ecosystem. The --daemon flag should not need to override the port since it would already be correct.
Environment
- hindsight-embed v0.4.6
- hindsight-api v0.4.6
Workaround
Pass --port 8889 when running hindsight-api directly.
Related
See #261 for related context.