Skip to content

fix: skip mkdir when C3 parent dir already exists - #15288

Open
AiAlchemist0 wants to merge 5 commits into
cloudflare:mainfrom
AiAlchemist0:fix/c3-mkdir-drive-root
Open

fix: skip mkdir when C3 parent dir already exists#15288
AiAlchemist0 wants to merge 5 commits into
cloudflare:mainfrom
AiAlchemist0:fix/c3-mkdir-drive-root

Conversation

@AiAlchemist0

@AiAlchemist0 AiAlchemist0 commented Aug 20, 2026

Copy link
Copy Markdown

Fixes #5448

create-cloudflare always mkdirSyncs the parent of the project path. On Windows that parent can be a drive root (E:\), which already exists and throws EPERM. Skip mkdir when the parent is already there.

  • Tests
    • Tests included/updated
  • Public documentation
    • Documentation not necessary because: this is internal mkdir behavior; no user-facing docs or CLI flag changed.

I used an assistant on the edit.

@github-project-automation github-project-automation Bot moved this to Untriaged in workers-sdk Aug 20, 2026
@workers-devprod
workers-devprod requested review from a team and emily-shen and removed request for a team August 20, 2026 16:43
@workers-devprod

workers-devprod commented Aug 20, 2026

Copy link
Copy Markdown
Contributor

Codeowners approval required for this PR:

  • @cloudflare/wrangler
Show detailed file reviewers
  • .changeset/c3-mkdir-drive-root.md: [@cloudflare/wrangler]
  • packages/create-cloudflare/src/tests/project-directory.test.ts: [@cloudflare/wrangler]
  • packages/create-cloudflare/src/cli.ts: [@cloudflare/wrangler]
  • packages/create-cloudflare/src/project-directory.ts: [@cloudflare/wrangler]

@devin-ai-integration devin-ai-integration Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

✅ Devin Review: No Issues Found

Devin Review analyzed this PR and found no bugs or issues to report.

Open in Devin Review

@pkg-pr-new

pkg-pr-new Bot commented Aug 20, 2026

Copy link
Copy Markdown
@cloudflare/autoconfig

npm i https://pkg.pr.new/@cloudflare/autoconfig@15288

@cloudflare/build-output-utils

npm i https://pkg.pr.new/@cloudflare/build-output-utils@15288

@cloudflare/codemods

npm i https://pkg.pr.new/@cloudflare/codemods@15288

@cloudflare/config

npm i https://pkg.pr.new/@cloudflare/config@15288

create-cloudflare

npm i https://pkg.pr.new/create-cloudflare@15288

@cloudflare/deploy-helpers

npm i https://pkg.pr.new/@cloudflare/deploy-helpers@15288

@cloudflare/kv-asset-handler

npm i https://pkg.pr.new/@cloudflare/kv-asset-handler@15288

miniflare

npm i https://pkg.pr.new/miniflare@15288

@cloudflare/pages-functions

npm i https://pkg.pr.new/@cloudflare/pages-functions@15288

@cloudflare/pages-shared

npm i https://pkg.pr.new/@cloudflare/pages-shared@15288

@cloudflare/unenv-preset

npm i https://pkg.pr.new/@cloudflare/unenv-preset@15288

@cloudflare/vite-plugin

npm i https://pkg.pr.new/@cloudflare/vite-plugin@15288

@cloudflare/vitest-plugin

npm i https://pkg.pr.new/@cloudflare/vitest-plugin@15288

@cloudflare/workers-auth

npm i https://pkg.pr.new/@cloudflare/workers-auth@15288

@cloudflare/workers-editor-shared

npm i https://pkg.pr.new/@cloudflare/workers-editor-shared@15288

@cloudflare/workers-utils

npm i https://pkg.pr.new/@cloudflare/workers-utils@15288

wrangler

npm i https://pkg.pr.new/wrangler@15288

commit: b920304

@changeset-bot

changeset-bot Bot commented Aug 20, 2026

Copy link
Copy Markdown

🦋 Changeset detected

Latest commit: b920304

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
create-cloudflare Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@AiAlchemist0

Copy link
Copy Markdown
Author

Added a unit test for the mkdir skip, and filled the tests/docs checkboxes in the description.

devin-ai-integration[bot]

This comment was marked as resolved.

@AiAlchemist0

Copy link
Copy Markdown
Author

Fixed import order for lint.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Untriaged

Development

Successfully merging this pull request may close these issues.

🐛 BUG: C3 run in root of drive fails with EPERM: operation not permitted

2 participants