Windows Computer Use fails at EnumWindows with 0x80070003
Open 💬 18 comments Opened Aug 5, 2026 by Moonst
Summary
The bundled Computer Use helper starts, but both sky.list_apps() andsky.list_windows() fail immediately with:
EnumWindows failed: The system cannot find the path specified. (0x80070003)
The failure survives a full Windows restart and a Codex restart.
Environment
- Windows 10 Home 22H2, build 19045.6466
- Codex Windows package:
OpenAI.Codex_26.730.8199.0_x64 - Computer Use plugin:
26.730.61639 @oai/sky:0.6.2- Computer Use runtime:
cua_node/fb8898c05a62885e - WebView2 Runtime:
151.0.4129.59
Verified behavior
node_repl.exestarts and imports@oai/skysuccessfully.codex-computer-use.exeexists and starts.sky.list_apps()fails with the error above.sky.list_windows()fails with the same error.- A direct Win32
EnumWindowsdiagnostic outside the helper returns normally. - The Windows desktop was unlocked and active.
Process context
node_repl.exeruns as the signed-in Windows user.codex-computer-use.exeruns asCodexSandboxOfflinein the same Windows session.
The isolated account's Desktop and Pictures values referenced local paths that
did not exist. Empty compatibility folders were created at those exact paths,
Codex was fully restarted, and the same EnumWindows error remained. The missing
folders were therefore ruled out as the cause.
Troubleshooting already completed
- Uninstalled and reinstalled the Codex desktop app.
- Restarted Windows multiple times.
- Verified the helper executable, Node runtime, and package files exist.
- Verified the signed-in user's OneDrive Desktop and Pictures paths exist.
- Created the isolated account's missing local Desktop and Pictures paths.
- Confirmed both lightweight enumeration APIs still fail after restart.
Expected behavior
sky.list_apps() and sky.list_windows() should return app/window objects so
Computer Use can target Windows applications.
Actual behavior
The native helper connects but aborts its first window enumeration with Windows
error 0x80070003, so no desktop application can be targeted or controlled.
18 Comments
I can reproduce the same regression on the same current package/plugin family, but my helper returns Win32 error 2 rather than error 3:
Environment
26200.8875OpenAI.Codex_26.730.8199.0_x6426.730.61639@oai/sky:0.6.2cua_node/fb8898c05a62885e627B317CCFD3C7386A2D5BC4FB4E97FF30E30425945A7A5370006AD89CF3605AUpdate/failure timeline (UTC)
sky.list_windows():2026-08-04 23:59:52Z2026-08-05 04:05Z26.727.6591.0→26.730.8199.00.146.0-alpha.9.2→0.147.0-alpha.1.226.727.51351→26.730.616392026-08-05 05:53:02ZThe AppX update completed successfully with no deployment warnings or errors.
Narrowing completed
cua_noderuntime,@oai/skyversion, and helper binary/hash.EnumWindowsprobe outside the Codex sandbox succeeds (319 top-level handles enumerated), so the host Windows API and active desktop are functioning.CodexSandboxOfflinetoken. Its inherited environment/profile references and its token-resolved profile do not agree, which may be relevant to a per-window executable/icon/profile lookup performed during the enumeration callback.This looks like a
26.730app-server/sandbox/window-enumeration integration regression rather than a missing helper binary. The0x80070002versus this issue's0x80070003may reflect different missing filesystem objects reached by the same enumeration callback path.I can reproduce this on a Windows ARM64 Qualcomm PC.
OpenAI.Codex_26.730.8199.0_arm6426.730.61639@oai/sky:0.6.2cua_node/f1359d6e9a17bb1dEnumWindows failed: The system cannot find the path specified. (0x80070003)The elevated sandbox and runtime permissions were repaired and verified. Both bundled x64 and ARM64 helpers produced the same error after full Windows and Codex restarts; the official x64 helper was restored. This confirms the regression also affects ARM64 and does not appear to be caused by helper architecture.
I am encountering a closely related failure with the same Computer Use plugin version,
26.730.61639, on Windows 11 x64.Both
sky.list_apps()andsky.list_windows()fail, but my error is slightly different:EnumWindows failed: The system cannot find the file specified. (0x80070002)I also found an apparent mismatch between the bundled Computer Use skill and
@oai/sky. The module loads and exposessky, but the documentation API required by the skill is absent:TypeError: sky.documentation is not a functionThe failure persisted after restarting Windows and the desktop app, reinstalling the plugin, starting a new task, and resetting the JavaScript runtime.
In-app diagnostic feedback ID:
019fd4c4-f84e-7fc0-a66d-a4ba7255bff7The matching plugin version and failing enumeration calls suggest this may share the same underlying Windows helper/runtime problem, despite the difference between
0x80070002and0x80070003.I can reproduce the same failure on a separate Windows 11 environment.
Environment
10.0.26200(build26200)OpenAI.Codex_26.730.8199.0_x6426.730.61639@oai/sky:0.6.2cua_node/fb8898c05a62885eObserved behavior
@oai/skyimports successfully, butsky.list_apps()fails before any target application can be selected:The bundled
codex-computer-use.exeexists at the expected package path.Additional troubleshooting completed
Ok.cua_node/fb8898c05a62885eruntime aside and restarted Codex, allowing the runtime to be downloaded and regenerated from scratch.node_repl.exe, Node runtime,@oai/sky, andcodex-computer-use.exeall exist.EnumWindowserror persisted after regeneration.CodexSandboxUsers; after that,@oai/skyloaded, but enumeration still failed with0x80070003.No application window can be enumerated or controlled, and Power Automate Desktop is never touched. This appears to be within the Windows Computer Use helper/enumeration layer rather than the target application.
I can reproduce this on Windows 11 Pro x64 with the same Codex package.
Environment
10.0.26200.8875OpenAI.Codex_26.730.8199.0_x6426.805.11740Observed behavior
In a fresh task, I asked Computer Use only to list the titles of the currently visible top-level Windows applications, without clicking, typing, launching, closing, or modifying anything.
It failed immediately with:
I can reproduce this on a Windows 11 Arm64 environment, with the same Computer Use plugin/runtime family.
Environment
10.0.26200.897326.730.61639@oai/sky:0.6.2cua_node/f1359d6e9a17bb1d627B317CCFD3C7386A2D5BC4FB4E97FF30E30425945A7A5370006AD89CF3605AObserved behavior
Both
sky.list_windows()andsky.list_apps()fail before any target app can be selected:The same failure persisted after resetting the JavaScript runtime and retrying the lightweight enumeration calls.
Additional narrowing
I also called the bundled helper directly over its JSON-line protocol. The helper executable starts and
diagnostic_statesucceeds, so this does not look like a missing helper binary or a Node import problem.Direct helper behavior differed depending on request metadata:
Arbitrary fake
session_id + turn_idvalues reproduced the same0x80070003, so the exact IDs do not appear to matter; the metadata shape does.This suggests the native helper may be taking a turn-scoped path when
turn_id/session_idmetadata is present, and then reporting a stale or unrelatedGetLastError()value as anEnumWindowsfailure after enumeration aborts. The0x00000000case especially looks likeEnumWindowsreturnedFALSEwithout a meaningful Win32 error being set.A related Windows observation from another task: the helper was installed and enabled, but trying to open NetEase Cloud Music failed before any app could be targeted. The observed error was
spawn EPERMrather than 0x80070003, and restarting/resetting did not restoresky.list_apps()orsky.list_windows(). This may be a separate earlier failure stage in the same native Computer Use helper path. Environment: Codex Desktop 26.730.8199.0, Computer Use plugin 26.730.61639, @oai/sky 0.6.2, Windows x64.Verified root cause and working fix/workaround
Short version:
codex-computer-use.exewas healthy, but it inherited an empty private Windows desktop namedWinsta0\CodexSandboxDesktop-....EnumWindowstherefore found zero top-level windows. The documented compatibility setting below makes sandboxed children use the interactiveWinsta0\Defaultdesktop instead:After changing
%USERPROFILE%\.codex\config.toml, fully exit every Codex/ChatGPT process and relaunch Codex. A normal task restart is not sufficient because the sandbox desktop and native pipe are created by the desktop-app process.This fixed Computer Use on the affected machine. After restart,
sky.list_windows()returned real Chrome, Steam, and Codex windows, and Computer Use worked normally.This option is documented in the current Windows sandbox guide as the compatibility switch for the older
Winsta0\Defaultbehavior. It preserves the elevated filesystem/network sandbox, but it intentionally gives up the stronger private-desktop UI isolation. Treat it as a compatibility workaround until the product correctly routes Computer Use to the active input desktop while private-desktop isolation is enabled.Root cause
The reported HRESULT is misleading. The failure was not a missing file/path, plugin binary, marketplace, native pipe, target app, or broken Windows
EnumWindowsAPI.The actual sequence was:
node_repl.exeand thencodex-computer-use.exeon a private desktop:Winsta0\CodexSandboxDesktop-<id>.list_windowspath calledEnumWindowsdirectly on its current thread desktop. It did not callOpenInputDesktoporSetThreadDesktopfirst.user32!EnumWindows,win32u!NtUserBuildHwndListreturnedSTATUS_SUCCESS, but the returned list hadneeded = 1, meaning only the terminating null entry and therefore zero enumerated windows.FALSEfromEnumWindowsfor that empty-list case without setting a new Win32 error.GetLastError()value into an HRESULT. On this machine it happened to be Win32 error 3 (0x80070003); other reports showing error 2 or even error 0 are consistent with the same stale-error behavior.So the useful diagnostic signature is not the exact
0x80070002/0x80070003suffix. It is: helper is alive + native transport works +EnumWindowsreturns false + helper is attached to an emptyCodexSandboxDesktop.How this was debugged
Environment reproduced here:
OpenAI.Codex_26.730.8199.0_x6426.730.61639@oai/sky:0.6.2627B317CCFD3C7386A2D5BC4FB4E97FF30E30425945A7A5370006AD89CF3605A...\@oai\sky\bin\windows\codex-computer-use.exe1. Separate bootstrap failures from enumeration failures
First verify that:
@oai/skyimports;codex-computer-use.exestarts;SKY_CUA_NATIVE_PIPE_DIRECTORYexists and the named pipe is present;sky.list_windows()reaches the helper and returns theEnumWindows failedmessage.If those are true, marketplace junctions and the native pipe are no longer the failing layer. Reinstalling the plugin/runtime does not address this desktop-selection failure.
2. Attach CDB to the live helper
Microsoft CDB was available at:
Find the helper PID:
A first breakpoint around
EnumWindowscaptured the return value, stack, and last-error state:Observed:
The helper call stack led to
codex_computer_use+0x1eed1, with thelist_windowscaller near+0xad6d9in this exact binary.3. Disassemble
user32!EnumWindowsand inspect the returned HWND-list countThe system implementation can be inspected without a live target:
On this Windows build, a breakpoint immediately after
NtUserBuildHwndListshowed:The relevant CDB tracepoint was:
user32offsets are Windows-build-specific; runuf user32!EnumWindowsfirst and place the breakpoint after theNtUserBuildHwndListcall on the machine being diagnosed.This proved that the syscall succeeded and returned an empty desktop window list. The stale
LastErrorwas unrelated to that successful syscall.4. Rule out the helper callback
LLVM's PE tools were sufficient; Ghidra was not required:
For helper SHA-256
627B...605A, theEnumWindowscallback was near RVA0xBDB32. Static disassembly showed every normal exit converging on:In other words, the callback returns
TRUE; it was not aborting enumeration because of a failed executable/icon/profile lookup.Breakpoints on this helper's
OpenInputDesktop,SetThreadDesktop,GetThreadDesktop, andCloseDesktopcall sites showed that none of them ran beforelist_windowscalledEnumWindows. This is important becauseSetThreadDesktopis thread-specific.5. Read the helper's inherited desktop from the PEB
With CDB attached:
Observed:
A direct PowerShell/Win32 probe running under the same Codex sandbox also reported a
CodexSandboxDesktop-*name andEnumWindows = FALSE, count0.6. Compare with the real input desktop
On a fresh diagnostic thread, the following sequence succeeded:
OpenInputDesktop(...)SetThreadDesktop(inputDesktop)GetUserObjectInformationW(..., UOI_NAME, ...)returnedDefaultEnumWindows(...)returnedTRUEand enumerated 295 handlesAs a final controlled proof, the unchanged signed helper was launched with
STARTUPINFO.lpDesktop = "Winsta0\\Default"while keeping the same stdio protocol and arguments. It immediately returned three real target windows. No helper binary patch was required.7. Apply the supported compatibility setting and restart
Back up
%USERPROFILE%\.codex\config.toml, add:If
[windows]already containssandbox = "elevated", add the new key to that existing table; do not create a duplicate TOML table.Then fully terminate all
ChatGPT.exe/Codex processes and relaunch the AppX app. Verify that:sky.list_windows()returns actual windows;Reusable prompt for future incidents
Useful search keywords:
The product-side fix should ideally keep private-desktop isolation for ordinary sandboxed commands while dispatching Computer Use enumeration/capture/input onto the active input desktop (or explicitly switching the dedicated Computer Use thread before enumeration), and it should not convert an unset/stale
GetLastError()into a misleading path/file HRESULT.Follow-up: the window-enumeration workaround fixed only the first half of Windows Computer Use. Screenshot capture and mouse input required resolving a second sandbox-identity problem.
Short version
This combination restored end-to-end window discovery, screenshots, and coordinate mouse input on the affected build:
After changing the existing
[windows]table, fully exit every Codex/ChatGPT process and relaunch the desktop app. A task restart alone is not sufficient.On this build, the task also had to use task-scoped Full Access. Keep reading before using that workaround because it has significant security implications.
Second root cause: Windows Graphics Capture ran under the wrong user context
With
sandbox = "elevated"andsandbox_private_desktop = false:sky.list_windows()worked and returned real windows.sky.get_window_state({ include_screenshot: true })reached Windows Graphics Capture.IGraphicsCaptureItemInterop::CreateForMonitorfailed with:The same error occurred against unrelated desktop windows, ruling out the target application and graphics injector/overlay.
The OneCore per-user capture-service template and signed system DLL were present and correctly registered. Its user-specific service instance was manual/demand-start and stopped, which is normal. The actual mismatch was that the elevated Codex sandbox used a dedicated offline sandbox identity, while Windows creates the per-user capture-service instance for the signed-in interactive user.
A minimal read-only A/B probe of the exact API confirmed this:
CreateForMonitor -> 0x80070424CreateForMonitor -> SUCCESSTherefore, deleting/recreating the capture-service registry keys was neither necessary nor the correct first fix. Switching to
windows.sandbox = "unelevated"put capture back in the interactive user's context.Third blocker: nested helper launch under the unelevated sandbox
After switching to
unelevated, the bundled@oai/skyWindows client could no longer start its helper while the task used the normal workspace sandbox:The bundled
@oai/skyversion launches the Windows Computer Use helper as a child process. A separate benign child-process probe reproduced the sameEPERMinside the unelevated sandbox, so this was not an application allowlist or capture-service failure.Selecting Full Access for the individual task removed that nested-process restriction. End-to-end verification then succeeded:
sky.list_windows()returned the permitted window.sky.get_window_state()returned a correctly rendered screenshot.If
node_repl exec context not foundappears during an app-approval callback, reset the Node kernel, then import@oai/sky, reacquire the window, capture, and perform the action in the same live JavaScript call.Security implications
This workaround deliberately weakens three isolation layers:
sandbox_private_desktop = falseplaces sandboxed UI work onWinsta0\Default, so it gives up private-desktop UI isolation.sandbox = "unelevated"uses a restricted token derived from the signed-in user instead of the stronger dedicated offline sandbox account. It is the documented compatibility/fallback mode and provides weaker isolation than the elevated implementation.Recommended precautions:
sandbox_mode = "danger-full-access"a global default.Suggested product-side fix
Ideally, Windows Computer Use should enumerate, capture, and inject input through a desktop-owned broker/native pipe running in the interactive user's context, while ordinary commands remain inside the elevated filesystem/network sandbox. The runtime should not require an extra helper child that the unelevated sandbox rejects. That would preserve strong command isolation without losing access to the active desktop or the signed-in user's per-user Windows Graphics Capture service.
Follow-up: security-preserving workaround for Windows screen capture and input (verified)
Short version: the strong Windows command sandbox does not need to be disabled. The workable design is to keep model-authored shell processes on the dedicated private desktop, while exposing screen capture and UI input as a separate, narrowly scoped, approval-gated capability launched by the trusted interactive Codex host.
The failure was architectural: the bundled helper inherited the sandbox process's window station, desktop, identity, and per-user service context. On that private desktop,
EnumWindowscorrectly found no interactive-user windows, and Windows Graphics Capture could not activate the interactive user's capture service. Patching only the staleGetLastError()handling would improve the diagnostic, but it would not make the user's windows or capture service available there.I verified a local proof-of-concept that keeps these settings enabled:
This is a local workaround/prototype, not an official OpenAI fix.
Architecture
The important distinction is that interactive UI control is treated as a separate privileged capability, not as a side effect of granting the shell access to the user's desktop.
Security properties
sandbox_private_desktop = falseare not required.Verification performed after a full Codex restart
Reusable implementation prompt
The implementation is large enough that pasting machine-specific files into this issue would be both noisy and unsafe. The following prompt captures the design and validation requirements without including any account name, computer name, local path, process ID, window title, or application-specific data:
Recommended product-level fix
The durable upstream solution is the same separation implemented as a supported Codex component: keep shell execution in the private desktop sandbox, and have the trusted desktop host own a narrow, approval-gated Computer Use broker on the interactive desktop. The broker should authenticate its parent/channel, expose no ambient IPC surface, enforce target restrictions, and emit privacy-safe audit events. Separately, the helper should clear/check last-error state correctly around
EnumWindowsso an empty desktop produces an accurate diagnostic rather than a stale HRESULT.That approach fixes window discovery, Windows Graphics Capture, and mouse/keyboard control without granting general shell processes access to the interactive desktop.
Update: correct Computer Use lifecycle cleanup
A later failure-recovery test found two separate lifecycle bugs in the prototype broker:
The corrected broker now:
finish_computer_usetool that ends the helper turn, closes the client/transport, clears every cached client reference and lifecycle flag, and forces the next UI operation to create a fresh client;The live failure-recovery sequence now passes: normal enumeration succeeds; an intentional nonexistent-window request fails as expected; the following finish call executes instead of replaying the earlier error; no helper remains attached; a subsequent enumeration succeeds through a fresh client; and the final finish again leaves no helper attached.
This cleanup does not weaken the security boundary. The elevated private desktop remains enabled for model-authored commands, every broker action remains approval-gated, target restrictions remain enforced, and no listener, service, shared endpoint, or broadly accessible IPC mechanism was added.
For future implementations, add these requirements to the reusable prompt above:
Update from the originally affected machine:
Setting the supported compatibility option below and fully restarting every Codex/ChatGPT process restored real window enumeration:
Current result:
This supports the private-desktop diagnosis already documented in this issue.
However, two separate failures remain after enumeration is restored:
Error: node_repl exec context not found
IGraphicsCaptureItemInterop.CreateForMonitor failed:
The specified service does not exist as an installed service. (0x80070424)
Full access previously allowed same-call screenshot/launch operations, but did not fix the cross-call exec-context failure. Therefore the EnumWindows compatibility setting fixes the enumeration layer only, not the complete Computer Use workflow.
I can reproduce the same failure in a separate Windows Codex Desktop session on 2026-08-06.
Environment
26.730.61639cua_nodewith@oai/sky019fd61e-c1ae-7b10-996a-8c642778157fExact failure
@oai/skyimports successfully, but the first window discovery call fails immediately:The failure occurs at
sky.list_apps(), before any target window can be returned, activated, captured, or controlled. Brave was never touched and no UI input was sent.Recovery attempts completed
The same error was reproduced after each of the following:
sky.list_apps()call.@oai/skyin the fresh kernel.Every attempt failed at the same enumeration boundary with
0x80070003.Separate bundled skill/runtime mismatch
The installed Computer Use skill instructs callers to load its required guidance with:
However, the loaded
skyobject does not expose adocumentationfunction:The runtime exposed these methods:
The installed Markdown documentation files were readable locally, so this API mismatch did not cause the
EnumWindowserror itself. It does indicate that the bundled skill instructions and the loaded@oai/skyAPI are out of sync in the same installation.Expected result
sky.list_apps()should return the currently available applications and windows, after which Computer Use should be able to select the existing Brave window and proceed through the normal safety controls.Actual impact
Computer Use is completely unavailable because failure occurs before app or window selection. The required recovery procedure was exhausted, and the task had to stop without inspecting or changing the target application.
I'm facing the same issue. Installed Computer Use and it just doesn't work. Windows 11. Tried all the workarounds it suggested: rebooting, re-installing etc.
Still reproducible after the current Codex/Computer Use update on 2026-08-07.
Environment:
OpenAI.Codex_26.803.5235.0_x6426.803.41515@oai/sky:0.6.2Observed result:
The failure persists after a full Windows restart, reinstalling and re-enabling the Computer Use plugin, starting a completely fresh Node REPL session, running the Windows Repair action for the Codex app without resetting app data, and restarting Codex.
There is also still a bundled skill/runtime mismatch: the installed skill requires
sky.documentation("guidance"), buttypeof sky.documentationis"undefined". The loaded runtime exposeslist_windows,list_apps, and the UI-control methods, but nodocumentationmethod.The failure occurs before any target application can be selected or accessed.
Update: I now have end-to-end Windows Computer Use working on the same affected machine.
Working combination
For the individual UI-testing chat, I selected Full access from the permissions control under the composer. I did not change the global
sandbox_modetodanger-full-access.In a fresh task, one live Computer Use execution successfully:
7button;0to7.This confirms that, on this machine,
elevated + sandbox_private_desktop = false + chat-scoped Full accessrestores window discovery, screenshot capture, and input. Ordinary Workspace access had continued to fail screenshot capture with0x80070424.Separate startup/config snag encountered while testing
I briefly changed the Windows sandbox to
unelevated. Codex then became stuck on Finish Windows setup, and Continue with limited access hung and disappeared without opening the normal app. Returning the config toelevateddid not immediately recover startup.A TOML validation/recovery pass then exposed an unexpected invalid line in
config.tomlthat I did not knowingly add. After removing that line, fully terminating all ChatGPT/Codex,node_repl, andcodex-computer-useprocesses, and restarting, the app loaded normally again. I cannot determine what inserted the line, so I am not attributing it to a specific component.The least-disruptive workaround currently working here is therefore:
sandbox = "elevated";sandbox_private_desktop = false;This is still a workaround rather than an upstream fix, but it restores the Chrome-extension UI-testing workflow that was blocked by this regression.
Confirmed on another Windows 11 Pro 25H2 x64 system.
The problem persists after:
Environment after the update:
Exact failure:
TypeError: sky.documentation is not a function
The bundled skill requires:
sky.documentation("guidance")
but the loaded runtime does not expose a documentation method.
Before the update:
After the update:
All checked runtime hashes and the export list remained unchanged through the
update.
node_repl starts successfully and @oai/sky imports. The failure occurs before
the first Computer Use UI method, so the visible Notepad test window was not
focused, edited, saved, or closed.
The Windows sandbox setup, command runner, sandbox accounts, firewall rules,
Defender state, and local ACL operations were checked separately and did not
show a blocker for this reproduction.
No fallback automation, runtime patching, ACL changes, security changes, app
reset, or repeated retries were used.
Independent reproduction from another Windows installation on 2026-08-07.
Environment
26.730.8199.0(x64)26.730.61639@oai/sky:0.6.2Reproduction
The supported package import succeeds, but both discovery calls fail immediately:
The failure reproduced in two separate Codex tasks:
019fde1e-db6b-7200-808e-ab3f7f52ebd1019fdad4-a5c2-7e90-bfe8-fbda4dd3b7f6Additional diagnostics
sky.close(), resetting the Node runtime, re-importing@oai/sky, and retrying did not change the failure.sky.get_window({ id })also failed with the sameEnumWindowserror.sky.get_window_state(...)bypassed that enumeration error, but failed withforeground window did not report a process id.sky.documentation(...), whiletypeof sky.documentationisundefinedin@oai/sky0.6.2.No ACL, private-desktop, sandbox, cache, or configuration changes were made. No fallback mouse or keyboard input was sent. These results seem consistent with the private-desktop/window-station boundary described above rather than a missing helper binary or stale Node session.
An in-app feedback upload is still pending because it requires a manual action in the Codex composer; I can add its ID afterward.
Same here
Codex 26.803.5235.0, plugin 26.803.41515, @oai/sky 0.6.2, and errors sky.documentation is not a function plus spawn EPERM
Win 11 , Codex Pro Max plan