[BUG] <`npm` is case-sensitive towards the drive letter in Windows 10 causing module name errors when using `npm run dev` in a NextJS project in the eshell tool within emacs>
Nobody has claimed this yet.
- Dominant language
- JavaScript
- Stars
- 10.1k
- Forks
- 4.7k
- Avg merge
- 2d 2h
- Merged PRs (30d)
- 19
Description
Is there an existing issue for this?
- I have searched the existing issues
This issue exists in the latest npm version
- I am using the latest npm
Current Behavior
I am an emacs user attempting to use eshell to use npm run dev in a NextJS project. I've configured the project from scratch as per the next docs, and this is the output:

Expected Behavior
The expected behavior should be that the server runs with no errors or warnings given that the project was setup exactly as the next docs instruct. I will note that if you delete node_modules and use the driveup tool in M-x shell instead of eshell, re-install the next dependencies and run npm run dev, it works as expected, so the lowercase drive letter is the issue.
Steps To Reproduce
- Install emacs as a
scoopapp:
scoop bucket add extras
scoop install emacs
- Run
emacs -Qin PowerShell (do not use an init file, run as default emacs) - Run
M-x eshellandcdinto an empty directory to configure the project - Run
npm i next react react-dom - Edit the
package.jsonwithM-x find-fileto add:
"scripts": {
"dev": "next dev"
},
- Run
npm run dev - See error.
Environment
- npm: 8.1.0
- Node.js: 16.13.0
- OS Name: Windows 10 Pro
- System Model Name: Dell Precision 5760
- npm config:
; "builtin" config from c:\Program Files\nodejs\node_modules\npm\npmrc
prefix = "C:\\Users\\me\\AppData\\Roaming\\npm"
; "user" config from C:\Users\me\.npmrc
//registry.npmjs.org/:_authToken = (protected)
; node bin location = c:\Program Files\nodejs\node.exe
; cwd = c:\Users\me\pandora\test-bug
; HOME = C:\Users\me
; Run `npm config ls -l` to show all defaults.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reproducing the report's Windows 10 setup with Emacs eshell, npm i next react react-dom, and npm run dev, comparing the lowercase and uppercase drive-letter paths. Then trace npm's handling of those paths; no source file or test is named in the report. Done means the Next.js development server runs without module-name errors in the stated setup.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- emacs, javascript, nextjs, nodejs
- Domain
- cli, operating-systems
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 35/100