#exec tool returns empty output on Windows - commands run instantly with no errors

1 messages · Page 1 of 1 (latest)

lime moat
#

Bug Description

The exec tool returns empty output on Windows. Commands appear to succeed (no errors in logs) but return nothing.

Steps to Reproduce

  1. Run any exec command (e.g., echo hello)
  2. Get empty result

Expected vs Actual

  • Expected: Command output (e.g., "hello")
  • Actual: Empty output, tool ends instantly (0ms in logs)

Environment

  • OpenClaw: 2026.2.15
  • Node.js: v25.5.0
  • OS: Windows_NT 10.0.19045
  • Config: tools.exec.host = "gateway", security = "full"

Logs

16:59:53 tool start: exec
16:59:53 tool end: exec ← instant, no duration

Notes

  • Works fine in regular terminal (node -e "spawn works")
  • No errors in gateway logs
  • sandbox.mode = "off"
  • exec.host = "gateway"
mental turretBOT
#

To help others find answers, you can mark your question as solved via Right click solution message -> Apps -> ✅ Mark Solution

loud charmBOT
#

That “exec returns instantly with empty stdout/stderr on Windows” is a known Windows bug in 2026.2.15 and it’s already fixed.

  • Fix landed in 2026.2.17: “Process/Windows: disable detached spawn in exec runs to prevent empty command output.” (#18067)
    So the real fix is: update OpenClaw to ≥ 2026.2.17.

What I’d do:

  1. Update
  • If you’re on a source install: openclaw update (or openclaw update --tag 2026.2.17)
  • If you’re on a global npm install: update via your package manager flow (or re-run the installer)
  1. Restart the Gateway after updating:
openclaw gateway restart
  1. Verify the Gateway is actually running the new version (Windows service / Scheduled Task can keep pointing at an old install):