Yes
I deleted the node_modules of my project and then proceeded to run npm install (to check if it was ready for version control), the npm install everything until there. When I run npm start, the public/index.html is loaded but appears that the src/index.js is not evaluated, I've checked this with come console logs. After a a while trying to understand what was going on I noticed that a part of my project path is called 'XXX%20-%20XX%20-%20XXX%20XXXX%20-%20XX' with this suspicion I have changed the name of the folder and now everyhing is working ok
npm start would start my app as normal with src/index.js being evaluated
npm start appears to be not loading src/index.js when the project file path contains '%'
npm ls react-scripts (if you haven鈥檛 ejected):node -v:npm -v:Then, specify:
Operating system:
Windows 10
Browser and version:
Firefox and Chrome (latest)
It's possible and might be a Webpack bug. Thanks for reporting, we'll report this upstream.
Can somebody verify this is reproducible?
Just ran into this, having a % in a path throws this error in the browser:
URIError: URI malformed
at decodeURIComponent (<anonymous>)
at getFilenameFromUrl (D:\%_newfolder\test2\node_modules\webpack-dev-middleware\lib\GetFilenameFromUrl.js:32:9)
at webpackDevMiddleware (D:\%_newfolder\test2\node_modules\webpack-dev-middleware\middleware.js:39:18)
at Layer.handle [as handle_request] (D:\%_newfolder\test2\node_modules\express\lib\router\layer.js:95:5)
at trim_prefix (D:\%_newfolder\test2\node_modules\express\lib\router\index.js:317:13)
at D:\%_newfolder\test2\node_modules\express\lib\router\index.js:284:7
at Function.process_params (D:\%_newfolder\test2\node_modules\express\lib\router\index.js:335:12)
at next (D:\%_newfolder\test2\node_modules\express\lib\router\index.js:275:10)
at next (D:\%_newfolder\test2\node_modules\express\lib\router\route.js:127:14)
at next (D:\%_newfolder\test2\node_modules\express\lib\router\route.js:131:14)
at next (D:\%_newfolder\test2\node_modules\express\lib\router\route.js:131:14)
at next (D:\%_newfolder\test2\node_modules\express\lib\router\route.js:131:14)
at next (D:\%_newfolder\test2\node_modules\express\lib\router\route.js:131:14)
at next (D:\%_newfolder\test2\node_modules\express\lib\router\route.js:131:14)
at next (D:\%_newfolder\test2\node_modules\express\lib\router\route.js:131:14)
at next (D:\%_newfolder\test2\node_modules\express\lib\router\route.js:131:14)
(and decodeURIComponent throws because % isn't a valid character in a URI).
Would you like to send a fix to Webpack?
@gaearon filed in as https://github.com/webpack/webpack-dev-middleware/pull/201 馃憤
Ooh nice. Let us know when it makes it into a stable release!
Shipped in [email protected] 馃巻
Closing as fixed.