You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
[BUG] when TOML contains a { charactor it failed to recognize it a valid TOML #4378
executing headroom wrap code command on my macbook(M series) will prompt me to this error message:
MCP retrieve tool: install failed (failed): /Users/codefox/.codex/config.toml is not valid TOML (Invalid initial character for a key part (at line 189, column 8)); refusing to overwrite. Fix or remove the file, then re-run.
Serena MCP: install failed (failed): /Users/codefox/.codex/config.toml is not valid TOML (Invalid initial character for a key part (at line 189, column 8)); refusing to overwrite. Fix or remove the file, then re-run.
╔═══════════════════════════════════════════════╗
║ HEADROOM WRAP: CODEX ║
╚═══════════════════════════════════════════════╝
Persistent deployment 'default' on port 8787 did not expose routing config; starting a dedicated proxy on a different port instead.
Port 8787 is in use, using port 8788 instead.
Warning: could not read the extensions of the proxy on port 8787; the dedicated proxy on port 8788 starts without any. Set HEADROOM_PROXY_EXTENSIONS=<names> to carry them.
Starting Headroom proxy on port 8788...
Logs: /Users/codefox/.headroom/logs/proxy-8788.log
Proxy ready — dashboard: http://127.0.0.1:8788/dashboard
Error: could not read Codex config for session routing: Invalid initial character for a key part (at line 189, column 8)
Thanks for the example. I reproduced that error with the multiline inline table on Python 3.11.17, 3.12.15 and 3.14.8. The same sample parses on Python 3.15.0. Headroom currently uses the standard library's tomllib on Python 3.11 and newer, so this appears to depend on the parser version rather than the { character alone.
Keeping the inline table on one line works on all four versions I checked:
env = { DINGTALK_Client_ID = "example" }
Which Python version is running your Headroom installation? That would help distinguish a compatibility limitation from a problem with how Headroom reads the file.
Keeping the env inline table on one line, as in the previous example, is the workaround I verified on Python 3.14.8. Please try that form and let me know whether this parsing error goes away.
Activity
Ehsan-hash commentedon Oct 22, 2026
Thanks for the example. I reproduced that error with the multiline inline table on Python 3.11.17, 3.12.15 and 3.14.8. The same sample parses on Python 3.15.0. Headroom currently uses the standard library's
tomllibon Python 3.11 and newer, so this appears to depend on the parser version rather than the{character alone.Keeping the inline table on one line works on all four versions I checked:
Which Python version is running your Headroom installation? That would help distinguish a compatibility limitation from a problem with how Headroom reads the file.
codeandroad commentedon Oct 24, 2026
python 3.14
Ehsan-hash commentedon Oct 24, 2026
Thanks, that matches the Python 3.14 result above. Its
tomllibimplements TOML 1.0, whose inline-table syntax does not allow those newlines between the braces.Keeping the
envinline table on one line, as in the previous example, is the workaround I verified on Python 3.14.8. Please try that form and let me know whether this parsing error goes away.codeandroad commentedon Oct 24, 2026
Yes, it did go away.
fix(codex): accept multi-line inline tables in Codex config.toml (hea…