Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Win: Can't load a module with a long path #1990

Closed
koichik opened this issue Jun 16, 2015 · 2 comments
Closed

Win: Can't load a module with a long path #1990

koichik opened this issue Jun 16, 2015 · 2 comments
Labels
confirmed-bug Issues with confirmed bugs. good first issue Issues that are suitable for first-time contributors. module Issues and PRs related to the module subsystem. windows Issues and PRs related to the Windows platform.

Comments

@koichik
Copy link
Contributor

koichik commented Jun 16, 2015

Since v2.2.0 (probably, related to 1bbf8d0), require() can't load a module with a path longer than 260 characters on Windows.

v2.1.0:

> require('C:/Users/koichik/git/isomorphic/fluxible-demo/node_modules/webpack/node_modules/watchpack/node_modules/chokidar/node_modules/anymatch/node_modules/micromatch/node_modules/braces/node_modules/expand-range/node_modules/fill-range/node_modules/repeat-string/index.js')
[Function: repeat]

v2.3.0:

> require('C:/Users/koichik/git/isomorphic/fluxible-demo/node_modules/webpack/node_modules/watchpack/node_modules/chokidar/node_modules/anymatch/node_modules/micromatch/node_modules/braces/node_modules/expand-range/node_modules/fill-range/node_modules/repeat-string/index.js')
Error: Cannot find module 'C:/Users/koichik/git/isomorphic/fluxible-demo/node_modules/webpack/node_modules/watchpack/node_modules/chokidar/node_modules/anymatch/node_modules/micromatch/node_modules/braces/node_modules/expand-range/node_modules/fill-range/node_modules/repeat-string/index.js'
    at Function.Module._resolveFilename (module.js:332:15)
    at Function.Module._load (module.js:282:25)
    at Module.require (module.js:361:17)
    at require (module.js:380:17)
    at repl:1:1
    at REPLServer.defaultEval (repl.js:154:27)
    at bound (domain.js:254:14)
    at REPLServer.runBound [as eval] (domain.js:267:12)
    at REPLServer.<anonymous> (repl.js:308:12)
    at emitOne (events.js:77:13)
@vkurchatkin
Copy link
Contributor

This is probably the same problem #1980

@vkurchatkin vkurchatkin added the windows Issues and PRs related to the Windows platform. label Jun 16, 2015
@ChALkeR ChALkeR added the module Issues and PRs related to the module subsystem. label Jun 16, 2015
@vkurchatkin vkurchatkin added good first issue Issues that are suitable for first-time contributors. module Issues and PRs related to the module subsystem. and removed module Issues and PRs related to the module subsystem. labels Jun 16, 2015
@Fishrock123 Fishrock123 added the confirmed-bug Issues with confirmed bugs. label Jun 16, 2015
targos added a commit to targos/node that referenced this issue Jun 16, 2015
nodejs#1801 introduced internal fs methods to speed up require.
The methods do not call path._makeLong like their counterpart
from the fs module. This brings back the old behaviour.

Fixes: nodejs#1990
Fixes: nodejs#1980
Fixes: nodejs#1849
piscisaureus pushed a commit that referenced this issue Jun 16, 2015
#1801 introduced internal fs methods
to speed up require. The methods do not call path._makeLong like their
counterpart from the fs module. This brings back the old behaviour.

Fixes: #1990
Fixes: #1980
Fixes: #1849

PR-URL: https://github.com/nodejs/io.js/pull/1991/files
Reviewed-By: Bert Belder <[email protected]>
@silverwind
Copy link
Contributor

Fixed by 671e64a

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
confirmed-bug Issues with confirmed bugs. good first issue Issues that are suitable for first-time contributors. module Issues and PRs related to the module subsystem. windows Issues and PRs related to the Windows platform.
Projects
None yet
Development

No branches or pull requests

5 participants