claude-code - 💡(How to fix) Fix [BUG] Cowork (desktop app): mkdir/os.makedirs does not persist to Windows filesystem — virtiofs FUSE_MKDIR not forwarded to Windows host [1 participants]

Official PRs (…)
ON THIS PAGE

Recommended Tools

×6

Utilities matched from this issue’s tags and category — try them while you read without losing context.

GitHub issue graph ai analysis

Paste a GitHub issue URL. We fetch that issue, discover linked issues from bodies/comments/timeline, collect linked pull requests, and produce a structured English report.

The report is written in English Markdown for sharing and archival.

Helpful · Quick feedback

Loading…
GitHub stats
anthropics/claude-code#49272Fetched 2026-04-17 08:45:58
View on GitHub
Comments
0
Participants
1
Timeline
4
Reactions
0
Participants
Timeline (top)
labeled ×3subscribed ×1

Error Message

mkdir appears to succeed (no error):

$ mkdir /sessions/.../mnt/Downloads/L968_FAA_Prescreen

os.stat() returns a valid inode — FUSE client cache has it:

$ python3 -c "import os; print(os.stat('/sessions/.../mnt/Downloads/L968_FAA_Prescreen'))" os.stat_result(st_mode=16877, st_ino=..., st_dev=..., ...)

But writing a file to the new directory fails:

$ python3 -c "open('/sessions/.../mnt/Downloads/L968_FAA_Prescreen/test.pdf','wb').write(b'test')" FileNotFoundError: [Errno 2] No such file or directory: '.../L968_FAA_Prescreen/test.pdf'

Windows Explorer confirms: the folder was never created on the Windows filesystem

Code Example

# mkdir appears to succeed (no error):
$ mkdir /sessions/.../mnt/Downloads/L968_FAA_Prescreen

# os.stat() returns a valid inode — FUSE client cache has it:
$ python3 -c "import os; print(os.stat('/sessions/.../mnt/Downloads/L968_FAA_Prescreen'))"
os.stat_result(st_mode=16877, st_ino=..., st_dev=..., ...)

# But writing a file to the new directory fails:
$ python3 -c "open('/sessions/.../mnt/Downloads/L968_FAA_Prescreen/test.pdf','wb').write(b'test')"
FileNotFoundError: [Errno 2] No such file or directory: '.../L968_FAA_Prescreen/test.pdf'

# Windows Explorer confirms: the folder was never created on the Windows filesystem
RAW_BUFFERClick to expand / collapse

Preflight Checklist

  • I have searched existing issues and this hasn't been reported yet
  • This is a single bug report (please file separate reports for different bugs)
  • I am using the latest version of Claude Code

What's Wrong?

In the Claude Cowork desktop app (Windows), creating new directories via os.makedirs(), os.mkdir(), or the bash mkdir command appears to succeed inside the VM but the directory is never actually created on the Windows filesystem.

The Cowork app mounts the user's Windows folders into the Linux VM via a virtiofs FUSE driver:

  • Windows path: C:\Users\<user>\Downloads
    • VM mount path: /sessions/<session>/mnt/Downloads
      • Mount type: fuse (rw, default_permissions, allow_other) When a new subdirectory is created inside the mount:
  1. os.makedirs("/sessions/.../mnt/Downloads/NewFolder") returns without error
    1. os.stat() on the new path returns a valid inode (the FUSE layer caches it)
    1. Any subsequent file write to that path returns [Errno 2] No such file or directory
    1. On the Windows side, the directory was never created — it does not exist When Claude (running in the Cowork VM) calls os.makedirs() or mkdir on a path inside the virtiofs-mounted Windows folder, the directory should be created on the actual Windows filesystem — not just in the FUSE client cache. Subsequent file writes to the new directory should succeed. Note: Writing files to pre-existing Windows directories works correctly. The bug is isolated to new directory creation.

What Should Happen?

When Claude (running in the Cowork VM) calls os.makedirs() or mkdir on a path inside the virtiofs-mounted Windows folder, the directory should be created on the actual Windows filesystem — not just in the FUSE client cache. Subsequent file writes to the new directory should succeed.

Error Messages/Logs

# mkdir appears to succeed (no error):
$ mkdir /sessions/.../mnt/Downloads/L968_FAA_Prescreen

# os.stat() returns a valid inode — FUSE client cache has it:
$ python3 -c "import os; print(os.stat('/sessions/.../mnt/Downloads/L968_FAA_Prescreen'))"
os.stat_result(st_mode=16877, st_ino=..., st_dev=..., ...)

# But writing a file to the new directory fails:
$ python3 -c "open('/sessions/.../mnt/Downloads/L968_FAA_Prescreen/test.pdf','wb').write(b'test')"
FileNotFoundError: [Errno 2] No such file or directory: '.../L968_FAA_Prescreen/test.pdf'

# Windows Explorer confirms: the folder was never created on the Windows filesystem

Steps to Reproduce

  1. Open Claude Cowork desktop app on Windows and start a new session.
  2. Grant Claude access to a Windows folder (e.g. Downloads) via the folder picker.
  3. Ask Claude to create a new subfolder inside that directory (e.g. "create a folder called TestFolder in Downloads and move these files into it").
  4. Claude runs os.makedirs("/sessions/.../mnt/Downloads/TestFolder") — returns no error.
  5. Claude attempts to write a file: open("/sessions/.../mnt/Downloads/TestFolder/file.pdf", "wb")
  6. Observe: FileNotFoundError: [Errno 2] No such file or directory
  7. Check Windows Explorer — TestFolder does not exist in Downloads.

Additional confirmation: os.stat() on the path after mkdir returns a valid inode, proving the directory is cached in the FUSE client layer but was never persisted to the Windows host filesystem.

Note: Writing files to pre-existing Windows directories (folders that already existed before the session) works correctly. The bug is isolated to newly created directories.

Claude Model

None

Is this a regression?

No, this never worked

Last Working Version

No response

Claude Code Version

Claude Cowork desktop app (Windows) — version unknown (no claude --version in Cowork)

Platform

Anthropic API

Operating System

Windows

Terminal/Shell

Windows Terminal

Additional Information

This bug affects all Cowork users on Windows. The Cowork desktop app mounts user Windows folders into a Linux VM via virtiofs FUSE. The FUSE layer accepts FUSE_MKDIR and returns success to the client, but never calls CreateDirectory on the Windows host — so the directory only exists in the FUSE client cache, not on disk.

This blocks any AI workflow that requires creating new output folders (e.g. organizing files into a new subfolder, saving generated reports to a new directory, etc.). Writing to pre-existing Windows folders works fine — only new directory creation is broken.

The expected behavior is that mkdir inside the virtiofs mount should be forwarded to the Windows host filesystem. This is a standard virtiofs operation and should work transparently.

Impact: This is a blocker for enterprise/team use cases where users expect Claude to be able to organize files into new folders autonomously, without needing to pre-create every destination directory manually.

extent analysis

TL;DR

The issue can be fixed by ensuring the virtiofs FUSE driver correctly forwards mkdir operations to the Windows host filesystem, potentially by modifying the FUSE driver or the Cowork app's interaction with it.

Guidance

  • Investigate the virtiofs FUSE driver configuration and implementation to ensure it properly handles mkdir requests and forwards them to the Windows host.
  • Verify that the FUSE driver is correctly mounted and configured for the Windows folder, checking for any permissions or access control issues.
  • Consider modifying the Cowork app to use a different method for creating directories, such as using the Windows API directly or a library that provides a more robust interface for interacting with the Windows filesystem.
  • Test the fix by attempting to create a new directory using the Cowork app and verifying that it is correctly created on the Windows host filesystem.

Example

No code example is provided as the issue is related to the interaction between the virtiofs FUSE driver and the Windows host filesystem, which requires a deeper understanding of the specific implementation and configuration.

Notes

The issue is specific to the virtiofs FUSE driver and the Cowork app's interaction with it, and may require modifications to the driver or the app to resolve. The fix may also depend on the specific version of the virtiofs FUSE driver and the Windows host operating system being used.

Recommendation

Apply a workaround by modifying the Cowork app to use a different method for creating directories, such as using the Windows API directly, until a fix for the virtiofs FUSE driver is available. This will allow the app to function correctly while a more permanent solution is developed.

Vote matrix · Quick signals

Works
Did the solution work? Tap to confirm.
Easy Fix
Was it a quick fix?
Time Saver
Did it save you time?
Blocking
Was it severely blocking?
Common Issue
Are others likely hitting this too?
Flaky / Intermittent
Is it intermittent?
Verified / Reproducible
Can you reproduce it reliably?
Loading…

Still need to ship something?

×6

Another batch ranked right after the header list — different links, same matching logic.

Back to top recommendations

TRENDING

claude-code - 💡(How to fix) Fix [BUG] Cowork (desktop app): mkdir/os.makedirs does not persist to Windows filesystem — virtiofs FUSE_MKDIR not forwarded to Windows host [1 participants]