Can't build astro if project path contains spaces on MacOS #12556
Labels
- P3: minor bug
An edge case that only affects very specific usage (priority)
ecosystem: upstream
Upstream package has issue
pkg: mdx
Issues pertaining to `@astrojs/mdx` integration
Astro Info
If this issue only occurs in one browser, which browser is a problem?
No response
Describe the Bug
This might be an NPM or a Vite problem but I just started using Astro and it refuses to build if the project path contains a space on MacOS: for example, ".../new website" does not build, while ".../website" does.
The error is as follows:
astro vscode [ERROR] [vite] cannot find entry point module '.../Documents/new%20website/Site/node_modules/@astrojs/mdx/dist/server.js'.
It goes away if I change the path to the project to this: ".../Documents/Website/Site/node_modules/@astrojs/mdx/dist/server.js"
It was easy to fix for me, but I imagine if for example someone's username contains a space then they are in deep trouble.
What's the expected result?
Astro building my site.
Link to Minimal Reproducible Example
should be trivial to reproduce - in my case I just used the blog template and created a scratch project under a path with a space in the pathname.
Participation
The text was updated successfully, but these errors were encountered: