Windows: cowork scheduled tasks flash visible WSL console window every few minutes
Description
On Windows 11, the cowork scheduled tasks feature (coworkScheduledTasksEnabled / ccdScheduledTasksEnabled) periodically spawns wsl.exe, which opens a visible console window that flashes on screen every ~5 minutes. This interrupts active work (typing, browsing, form entry) by stealing focus momentarily.
The window title bar shows C:\Program Files\WSL\wsl.exe and it opens and closes within a second or two.
Steps to reproduce
- Windows 11 Pro (10.0.26200) with WSL2 installed
- Claude Desktop v1.1.7714.0
- Enable
coworkScheduledTasksEnabled: trueandccdScheduledTasksEnabled: trueinclaude_desktop_config.json - Use the computer normally — within ~5 minutes a
wsl.execonsole window will flash open and close
Expected behaviour
Background wsl.exe invocations should be invisible to the user. The process should be spawned with CREATE_NO_WINDOW or DETACHED_PROCESS flags, or use wslservice instead.
Workarounds attempted (none fully work)
- PowerShell script polling to hide windows: Too slow, window still flashes briefly
- Windows Terminal as default console host: WSL calls open as tabs in the active terminal, still disruptive
- Windows Terminal with
windowingBehavior: "useNew": Opens new terminal windows, still visible
Environment
- Windows 11 Pro 10.0.26200
- WSL version 2.6.3.0
- Claude Desktop v1.1.7714.0 (Windows Store)
- Default WSL distro: docker-desktop
Suggested fix
When spawning wsl.exe on Windows, use CREATE_NO_WINDOW process creation flag:
// Node.js example
const { spawn } = require('child_process');
spawn('wsl.exe', [...args], {
windowsHide: true, // Sets CREATE_NO_WINDOW
stdio: 'pipe'
});
This is a one-line change (windowsHide: true in Node.js spawn options) that would fix the issue for all Windows users.
This issue has 3 comments on GitHub. Read the full discussion on GitHub ↗