Describe the bug
Multiple built-in plugins fail to load at Gateway startup with RangeError: Maximum call stack size exceeded. This affects the following plugins:
minimax
google
talk-voice
Error Log
[plugins] minimax failed to load from .../openclaw/dist/extensions/minimax/index.js: RangeError: Maximum call stack size exceeded
[plugins] google failed to load from .../openclaw/dist/extensions/google/index.js: RangeError: Maximum call stack size exceeded
[plugins] talk-voice failed to load from .../openclaw/dist/extensions/talk-voice/index.js: RangeError: Maximum call stack size exceeded
Environment
- OS: Windows_NT 10.0.20348 (x64) / Windows Server 2019
- Node.js: v24.14.1
- OpenClaw: v2026.4.26
- Deployment: Local (npm global install)
Root Cause Analysis
After investigation, the root cause is: the ESM import chain for these bundled plugins is extremely deep (index.js → 20+ shared chunks → cross-references between chunks), which exhausts the Node.js default call stack size during module resolution.
Verification: Loading the same module with --stack-size=65536 succeeds without errors.
node --stack-size=65536 -e require("./minimax/index.js") # succeeds
node -e require("./minimax/index.js") # fails with RangeError
Workaround
Setting NODE_OPTIONS=--stack-size=65536 (user-level environment variable) resolves the issue, but requires a Gateway restart to take effect.
Suggested Fix
- Reduce the depth of the ESM import chain for these plugins (bundle optimization / chunk merging)
- Or set a higher default stack size in the Gateway launcher for Windows environments
- Or catch the error gracefully and skip the plugin with a warning instead of crashing
Impact
- These plugins are completely non-functional
- Workaround requires environment variable change + Gateway restart
- Affects all Windows deployments with these bundled plugins
Describe the bug
Multiple built-in plugins fail to load at Gateway startup with
RangeError: Maximum call stack size exceeded. This affects the following plugins:minimaxgoogletalk-voiceError Log
Environment
Root Cause Analysis
After investigation, the root cause is: the ESM import chain for these bundled plugins is extremely deep (
index.js→ 20+ shared chunks → cross-references between chunks), which exhausts the Node.js default call stack size during module resolution.Verification: Loading the same module with
--stack-size=65536succeeds without errors.Workaround
Setting
NODE_OPTIONS=--stack-size=65536(user-level environment variable) resolves the issue, but requires a Gateway restart to take effect.Suggested Fix
Impact