feat: OpenClaw HTTP bridge, HA conversation agent fixes, voice pipeline tooling

- Add openclaw-http-bridge.py: HTTP server translating POST requests to OpenClaw CLI calls
- Add launchd plist for HTTP bridge (port 8081, auto-start)
- Add install-to-docker-ha.sh: deploy custom component to Docker HA via SSH
- Add package-for-ha.sh: create distributable tarball of custom component
- Add test-services.sh: comprehensive voice pipeline service checker

Fixes from code review:
- Use OpenClawAgent (HTTP) in async_setup_entry instead of OpenClawCLIAgent
  (CLI agent fails inside Docker HA where openclaw binary doesn't exist)
- Update all port references from 8080 to 8081 (HTTP bridge port)
- Remove overly permissive CORS headers from HTTP bridge
- Fix zombie process leak: kill child process on CLI timeout
- Remove unused subprocess import in conversation.py
- Add version field to Kokoro TTS Wyoming info
- Update TODO.md with voice pipeline progress
This commit is contained in:
Aodhan Collins
2026-03-08 22:46:04 +00:00
parent 6a0bae2a0b
commit 664bb6d275
16 changed files with 1901 additions and 15 deletions

View File

@@ -187,8 +187,6 @@ class OpenClawCLIAgent(AbstractConversationAgent):
async def _call_openclaw_cli(self, message: str) -> str:
"""Call OpenClaw CLI and return the response."""
import subprocess
cmd = [
"openclaw",
"agent",
@@ -196,6 +194,7 @@ class OpenClawCLIAgent(AbstractConversationAgent):
"--agent", self.agent_name,
]
proc = None
try:
proc = await asyncio.create_subprocess_exec(
*cmd,
@@ -215,6 +214,9 @@ class OpenClawCLIAgent(AbstractConversationAgent):
return stdout.decode().strip()
except asyncio.TimeoutError:
if proc is not None:
proc.kill()
await proc.wait()
_LOGGER.error("Timeout calling OpenClaw CLI")
return "I'm sorry, the request timed out."
except FileNotFoundError: