Repository navigation
Description
Environment
- Codex desktop Windows package version:
26.1016.6573.0(from the running executable's package path) - OS: Windows
10.0.26300.0, x64 - Observed: October 21, 2026
Summary
Starting a new chat in Worktree mode fails with:
Error starting chat
Cannot serialize value: (couldn't stringify value)
This reproduces across multiple repositories. Starting a chat in Local mode works, and an existing conversation can continue receiving messages.
Steps to reproduce
- Open a Git repository in the Codex desktop app on Windows.
- Start a new chat with Worktree selected.
- Enter a prompt and submit it.
- Observe the error above; the Worktree chat does not start.
- Repeat with other repositories: the same failure occurs.
- Start a chat in Local mode instead: it works.
Expected behavior
Submitting the first message in Worktree mode creates the worktree and starts the chat successfully.
Diagnostics
The desktop logs contain five occurrences of [Composer] submit failed, all with mode=worktree, errorName=TypeError, and the same serialization error. The stack includes:
TypeError: Cannot serialize value: (couldn't stringify value)
at e.devaluateImpl (app://-/assets/app-shared-9cc135f1bdc1.js:323:30469)
at e.devaluateImpl (app://-/assets/app-shared-9cc135f1bdc1.js:323:30678)
at e.devaluateImpl (app://-/assets/app-shared-9cc135f1bdc1.js:323:30678)
at e.devaluateImpl (app://-/assets/app-shared-9cc135f1bdc1.js:323:30678)
at e.devaluateImpl (app://-/assets/app-shared-9cc135f1bdc1.js:323:30786)
at e.devaluate (app://-/assets/app-shared-9cc135f1bdc1.js:323:30106)
at Tft.sendCall (app://-/assets/app-shared-9cc135f1bdc1.js:323:49310)
at e.call (app://-/assets/app-shared-9cc135f1bdc1.js:323:44320)
at pY (app://-/assets/app-shared-9cc135f1bdc1.js:323:16306)
at Object.apply (app://-/assets/app-shared-9cc135f1bdc1.js:323:16382)
at SXi (app://-/assets/app-initial-2b6b8063022d.js:2519:8330)
The stack locates the observed failure in request serialization, but does not identify the value that cannot be serialized. An earlier working version and the root cause have not been established.
Related reports
- [Linux] New Worktree chats fail with Cannot serialize value, while Local mode works #55823 reports the same Worktree-versus-Local behavior on Linux.
- macOS app 26.1016.51333: new chats fail on first message with Cannot serialize value (couldn't stringify value) #55744 reports the same error text when starting chats on macOS.
This report adds the Windows occurrence and its stack trace; a shared root cause has not been confirmed.
Activity
github-actions commentedon Oct 21, 2026
Potential duplicates detected. Please review them and close your issue if it is a duplicate.
Powered by Codex Action
saberuster commentedon Oct 21, 2026
Additional Windows investigation for package version
26.1016.6573.0: the installed client contains a reproducible incompatibility between ProseMirror document attributes and the RPC serializer used bymanagedWorktrees.pending.create(...).Evidence from the installed build
startandendattributes to every non-text node, including the rootdocnode.Object.create(null). ItsNode.toJSON()retains that attribute map by reference; it does not turn it into an ordinary object.openingPromptForHistory.documentfrom the editor document'stoJSON()result.managedWorktrees.pending.create(...).Object.prototype. It classifies a null-prototype attribute map as unsupported. Formatting that unsupported value into an error string also throws, producing the exact fallback messageCannot serialize value: (couldn't stringify value).The implicated payload path is:
That path has three enclosing object levels beneath the argument array, matching the three object-recursion frames and one array-recursion frame in the reported stack.
Isolated reproduction with the installed functions
I extracted and executed the installed build's original attribute-construction function,
Node.toJSON()method, value classifier, and serializer in a separate Node process, with synthetic data and no changes to the app.attrscontainingstartandendJSON.parse(JSON.stringify(document))before serializationA small synthetic example illustrates the problematic value (the full reproduction above used the installed serializer, not a replacement implementation):
Build locations useful for finding the relevant code:
app-primary-98d23d806dbd.js:iptbuilds first-message history; the Worktree submit path passes it to the pending request.app-initial-2b6b8063022d.js:SXicallsmanagedWorktrees.pending.create.app-shared-9cc135f1bdc1.js:nlnschema builder,GGe/KGeattribute construction,oF.toJSON,QJclassifier, andDY.devaluateImpl.Suggested fix and regression coverage
Normalize the JSON-compatible editor document at the RPC boundary, or explicitly support null-prototype property maps in the serializer. Normalizing only the root with object spread is insufficient because nested node/mark attributes can have the same prototype.
A regression test should pass a fresh modern-composer document through the actual Worktree pending-create RPC serialization path, including root, child-node, and mark attributes.
The visible "plain text composer" setting does not appear to avoid this path: inspection shows it changes parsing/formatting while retaining the modern rich-text schema.
Evidence scope: this establishes the serialization incompatibility and an isolated fix using the shipped functions. I have not captured the failing live payload at a debugger breakpoint, patched the installed application, or verified a complete GUI fix. The manual-worktree-plus-Local workflow is a proposed bypass, not an end-to-end fix tested in this investigation.
frankbuckley commentedon Oct 21, 2026
Confirmed workaround and additional Windows reproduction evidence
This adds an end-to-end workaround confirmation to the analysis above, plus a consolidated reproduction of the startup failure.
Environment: Codex desktop on Windows x64, package
26.1016.6573.0; observed 21 October 2026. Six matching failures were recorded between 09:45:32 and 09:48:16 UTC, all withmode=worktree. This investigation tested one local Git project and installation.Reproduction
Expected: create the worktree and start the chat.
Cause and isolated validation
The implicated value is:
The editor schema adds
startandendattributes to non-text nodes, including the root document. Its attribute factory constructs that dictionary withObject.create(null); both defaults areundefined.Node.toJSON()retains the attributes dictionary. The new Worktree submission passes the history document directly tomanagedWorktrees.pending.create().The installed RPC classifier (
QJ) accepts ordinary objects when their prototype isObject.prototype, but rejects this null-prototype dictionary. Interpolating the rejected value into its diagnostic message also fails, producing the fallback error above.Minimal reconstructed request shape:
An isolated test using the installed attribute factory,
Node.toJSON()method, classifier, and serializer reproduced the exact TypeError and matching recursion pattern: unsupported value → three enclosing objects → arguments array. JSON normalization of the reconstructed request passes, as does a text-only history entry without the optional document.Evidence limit: the original live request was not captured from app memory; the field identification comes from installed-source tracing and the deterministic reproduction matching the logged failure. No installed app files, project files, or settings were patched.
Confirmed workaround: Local → Hand off → Worktree
The affected user tested these steps and confirmed the handoff succeeded in the same installation:
This preserves Worktree use while bypassing the failing new-chat startup request. It is a confirmed workaround, not a fix to direct Worktree chat creation.
Suggested upstream fix: normalize the history document subtree into ordinary serializable data before the RPC boundary, or safely support null-prototype dictionaries in the serializer. A shallow copy of the outer request is insufficient because nested node/mark attributes can have the same prototype. Regression coverage should include a fresh editor document with root, child-node, and mark attributes.
Raw logs and private project paths are omitted.
mjuik98 commentedon Oct 21, 2026
Additional Windows reproduction with sanitized desktop-log evidence.
OpenAI.Codex 26.1016.6573.010.0.26300, x64Cannot serialize value: (couldn't stringify value).The October 21 desktop logs contain 12 matching failures across two app sessions, all with
[Composer] submit failed,errorName=TypeError, andmode=worktree:Representative stack from the desktop log:
Installed-source inspection places this stack at the
managedWorktrees.pending.create(...)RPC boundary. The failing live value has not been captured in this installation, so this report confirms the symptom and call path rather than independently proving the specific attribute-level cause discussed above.No full conversation transcripts, account identifiers, private project paths, source code, or credentials are included.
sined-rahkuk commentedon Oct 21, 2026
confirming this on Windows x64 with Codex desktop package
26.1016.6573.0, observed on 21 October 2026.starting a new chat with Worktree enabled repeatedly fails with:
turning off Worktree lets the same project start a Local chat successfully. The failure also persisted across an app restart. After cleaning up obsolete worktrees, I tried again and still got the same error.
local logs show
mode=worktreeand aTypeErrorin the renderer RPC serialization path atmanagedWorktrees.pending.create(...), before the worktree creation request is dispatched. I have not captured the unsupported live value, so I cannot independently confirm the field-level cause discussed above.this is blocking normal new-chat startup in Worktree mode and disrupting my daily workflow. Please prioritize a fix in a released desktop build. Local mode is a workaround, but direct Worktree startup remains broken.
private logs, project content and filesystem paths are omitted.
cicely-f commentedon Oct 22, 2026
[Codex]
Additional Windows reproduction on 22 October 2026, with locally verified desktop-log evidence.
OpenAI.Codex 26.1016.6573.0.0.163.0-alpha.11.[Composer] submit failedentries between 01:03:19.585 and 01:09:48.613 UTC, across two app launches. Every matching entry hasmode=worktreeand the same TypeError, so an app restart did not clear the failure.The visible error remains:
The stack matches this issue, including
e.devaluateImplinapp-shared-9cc135f1bdc1.js:323andSXiinapp-initial-2b6b8063022d.js:2519:8330. Installed-source inspection places that call atmanagedWorktrees.pending.create(...), where RPC argument serialization fails before the request is sent.This confirms the symptom and call path in another installation; the unsupported live value was not captured here, so this is not independent confirmation of the specific attribute-level cause discussed above. Local mode is a confirmed workaround in this installation. A subsequent end-to-end Local-to-Worktree handoff test also succeeded, as detailed below.
Private project names, filesystem paths, prompt contents, and full logs are omitted.
Update: Local → Hand off → Worktree verified successfully
Tested on 22 October 2026 in the same Windows installation and affected local Git project:
Readyand explicitly forbidding file reads or changes.Ready.Worktree ready.Both the source checkout and destination worktree were clean afterwards. The source remained on
mainat its baseline commit. The destination was hydrated withgit lfs pull; all 4,618 tracked LFS files contained real content, with zero pointer placeholders.Prerequisite observed: the source checkout must be on a named branch. Handoff refused a detached HEAD; after an unrelated review finished and restored clean
main, the handoff succeeded. An initial transient “pending composer state” error cleared after opening the test chat.No project files were edited. This verifies chat creation in Local mode, native handoff, checkout isolation, asset hydration, and successful message delivery afterwards. No game build or gameplay tests were run. It is a verified workaround for using Worktrees in this installation, not a fix for direct new-chat creation in Worktree mode.
Private project identifiers, paths, and full logs remain omitted.
noduritoto commentedon Oct 22, 2026
261022_10:17:14 / DESKTOP-3NG6JGE / Codex Desktop
Additional Windows reproduction on 2026-10-22 (Asia/Seoul).
OpenAI.Codex_26.1016.6573.0_x64.[Composer] submit failedentries with the exactTypeError: Cannot serialize value: (couldn't stringify value); the matching entries identifymode=worktree.2026-10-22T00:43:14.384Zto2026-10-22T01:09:48.918Z(09:43–10:09 Asia/Seoul).e.devaluateImpl→e.devaluate→Tft.sendCall→e.call→pY→Object.apply→SXi→ composer submit.This independently confirms the same visible failure and shipped asset stack. We have not captured the live failing payload or independently verified the null-prototype explanation. We have not modified installed app files or tested the Local → Hand off → Worktree workaround on this installation yet.
Private project paths, prompts, and full raw logs are omitted.
Jztice5 commentedon Oct 22, 2026
Additional Windows reproduction on 22 October 2026, with locally inspected desktop logs.
Cannot serialize value: (couldn't stringify value).The matching logs show
[Composer] submit failed,errorName=TypeError, andmode=worktree. Representative frames:Read-only inspection of the installed JavaScript places the failing call at
managedWorktrees.pending.create(...), during RPC serialization before the worktree creation request is sent. The unsupported live value was not captured in this installation, so this confirms the symptom and call path, not an independent proof of the specific attribute-level cause discussed above.Local mode is a confirmed workaround here; Local-to-Worktree handoff has not been tested in this installation. No installed application files were modified. Private project paths, prompt contents, credentials, contact information, and full logs are omitted.
Hasteroth commentedon Oct 22, 2026
Additional independent reproduction on Windows, observed 21 October 2026 (America/Toronto), confirming the editor/serializer incompatibility described in the earlier investigation.
Version and user-visible reproduction
OpenAI.Codex 26.1016.6573.0.26.1016.51333, build21161, production channel.up_to_dateduring this investigation.Steps reproduced by the affected user:
mainbranch, and submit a short, newly typed prompt without attachments.Matching desktop logs show
[Composer] submit failed,mode=worktree, and a TypeError at the renderer RPC boundary. Representative frames:Installed-source inspection places this at
managedWorktrees.pending.create(...), before the Git worktree operation or environment setup begins.Reproduction using the shipped editor and serializer
Copies of the installed JavaScript modules were loaded in an isolated Node process using an already-installed
happy-domdependency. This used the original modern-composer schema/Markdown parser and RPC serializer, rather than replacement implementations.For the Markdown parser's input
hello, the actual document JSON was:{"type":"doc","attrs":{"start":0,"end":5},"content":[{"type":"paragraph","attrs":{"start":0,"end":5},"content":[{"type":"text","marks":[{"type":"startend","attrs":{"start":0,"end":5}}],"text":"hello"}]}]}Although this prints as ordinary JSON, the original root, paragraph, and mark attribute records have null prototypes. Scanning with the shipped classifier finds unsupported values at:
The shipped serializer was then tested with an RPC argument array containing a minimal pending-request-shaped object and this history document:
hellohello**hello**Proposed fix
Normalize the JSON-compatible opening-prompt history DTO before passing the pending request to
managedWorktrees.pending.create. For example:The equivalent normalization passed all three isolated tests above. This is a proposed source fix, not an installed patch. A source-level implementation could normalize only the document if that better matches the DTO contract. A shallow spread of the document is insufficient because child-node and mark attributes have the same problem.
Suggested regression coverage: serialize a complete pending-create request containing a fresh modern-composer document, including root, paragraph, and mark attributes. Verify that the actual Worktree creation RPC completes.
Independently verified operational workaround
The supported Codex app
create_threadtool successfully created a new Worktree chat for the same affected project, withenvironment.type = "worktree"and an existingmainstarting branch. Its read-only first turn completed successfully. Git inspection in that chat confirmed:Automatic dependency setup was not verified or retried. This establishes a working tool-based creation path with checkout isolation; it does not repair the manual composer.
Evidence limits
The failing live GUI payload was not captured at a debugger breakpoint, and the protected installed application was not modified. The isolated tests independently establish the shipped editor/serializer incompatibility and a passing normalization fix; a patched desktop app has not been tested end to end.
Private project names, filesystem paths, repository commits, chat/account identifiers, project source, screenshots, and full logs are omitted.
aviy009 commentedon Oct 22, 2026
I'm having the same issue with Version 26.1016.51333 on windows
IliyaBrook commentedon Oct 22, 2026
macOS users in #55744 report that 26.1016.61520 fixes this Worktree startup error, and that issue has now been closed as completed.
When will the same fix be available for Windows? I am still on 26.1016.51333 (build 21161, production channel), and the updater reports that I am up to date. No newer version is being offered to me.
It is frustrating to see the problem fixed on macOS while Windows users are still stuck with the broken Worktree startup and no release timeline. Could you please share an ETA for the Windows fix, or the exact Windows build that includes it and how to obtain it?
shiwandehongbai commentedon Oct 22, 2026
Windows production follow-up, observed on 22 October 2026 (UTC+8): this still affects package 26.1016.6573.0, desktop 26.1016.51333, build 21161. The app's configured updater currently returns up_to_date on the prod channel.
Local desktop logs contain seven matching
Composer submit failederrors today, all withmode=worktree; six occurred between 16:22 and 16:23 UTC+8. Subsequentthread/startandturn/startrequests succeeded. The failing stack matches this issue'sapp-shared-9cc135f1bdc1.js/SXi/app-initial-2b6b8063022d.jslocations.We also checked the installed source and reproduced the earlier diagnosis in an isolated Node process using the shipped attribute builders, Node/Mark
toJSON, request builder, classifier, and serializer:args[0].openingPromptForHistory.document.attrs; child-node and mark attributes have the same null prototype.openingPromptForHistorywithJSON.parse(JSON.stringify(...))before the pending-create RPC passes all three cases without modifying the original document or unrelated request fields.This confirms the existing root-cause diagnosis and candidate fix; it is not an installed patch or a new live-debugger payload capture. No application files or settings were modified. Private paths, prompts, repository details, chat identifiers, and full logs are omitted.
Given the macOS fix reports in #55744, could you confirm which Windows build includes the fix and when it will reach the production updater?
brefledev commentedon Oct 22, 2026
Adding my own confirmation: I’m seeing this on Windows in Codex Desktop 26.1016.51333 (package 26.1016.6573.0). Starting a new chat with Worktree selected fails on the first message with
Cannot serialize value: (couldn't stringify value). My logs show five[Composer] submit failedentries, all withmode=worktree. The macOS report says version 26.1016.61520 fixed it there. Which Windows build includes the fix, and when should it reach production?IliyaBrook commentedon Oct 22, 2026
Update: the 26.1016.61520 update has now arrived on Windows, and I have installed it. This version has completely resolved the Worktree startup bug for me. New Worktree chats now start successfully without the serialization error. Thank you for the fix!
bbqribs commentedon Oct 22, 2026
Also affected on Windows: app 26.1016.51333, package 26.1016.6573.0.
Identical error and stack; reproduced in a fresh Git repo containing only one committed README file.
Updater still says I'm up-to-date.
2026-10-21T23:01:10.822ZTypeError: Cannot serialize value: (couldn't stringify value)e.devaluateImpl → Tft.sendCall → SXi → …C:\Users\<redacted>\Documents\Coding\<repo>no-active-thread-01a160bd-bdab-76f3-9889-ca1dddee9554renderer-excerpt-redacted.txt