hydrogen
hydrogen copied to clipboard
Hydrogen dev codegen fails on Windows with double-“Users” path causing EPERM
What is the location of your example repository?
C:\Users\grim\hydrogen-storefront
Which package or tool is having this issue?
Hydrogen
What version of that package or tool are you using?
2025.5.1
What version of Remix are you using?
2.16.0
Steps to Reproduce
- On Windows, create or clone a Hydrogen storefront at
C:\Users\grim\hydrogen-storefront - Run
pnpm install - Run
shopify hydrogen dev --codegen - Observe that Vite tries to create directories under
C:\Users\Users\grim\hydrogen-storefront\node_modules\… - Build fails with:
Error: EPERM: operation not permitted, mkdir 'C:\Users\Users\grim\hydrogen-storefront\…\+types'
Expected Behavior
Expected Behavior
The codegen step should create virtual-routes in the correct project path
(C:\Users\grim\Desktop\hydrogen-storefront\node_modules\…) without permission errors.
Actual Behavior
Vite/React-Router dev plugin resolves the home directory as C:\Users\Users\grim,
causing an EPERM when attempting mkdir on that invalid path.