stylus: failed to locate @import file in windows

this is a dump of what my console says when i request /stylesheets/style.css within windows 7 express and jade work fine.

this is basicly the socket.io chat example wich i try running on windows.

d:\node\chat>node app.js
   app listening on http://0.0.0.0:12345
Error: D:\node\chat\public\stylesheets\style.styl:119
   115|     right 5px
   116|
   117| button
   118|   download-button()
 > 119|

failed to locate @import file d:\node\node_modules\stylus\lib/functions.styl

    at Evaluator.visitImport (d:\node\node_modules\stylus\lib\visitor\evaluator.js:567:21)
    at Evaluator.<anonymous> (d:\node\node_modules\stylus\lib\visitor\index.js:29:39)
    at Evaluator.visit (d:\node\node_modules\stylus\lib\visitor\evaluator.js:70:18)
    at Evaluator.<anonymous> (d:\node\node_modules\stylus\lib\visitor\evaluator.js:99:10)
    at Array.forEach (native)
    at Evaluator.setup (d:\node\node_modules\stylus\lib\visitor\evaluator.js:96:16)
    at Evaluator.evaluate (d:\node\node_modules\stylus\lib\visitor\evaluator.js:138:8)
    at Renderer.render (d:\node\node_modules\stylus\lib\renderer.js:50:26)
    at d:\node\node_modules\stylus\lib\middleware.js:148:17
    at [object Object].<anonymous> (fs.js:108:5)

i edited the chat example because require.paths does not work anymore it seems.

i simply commented this line out: _require.paths.unshift(_dirname + ‘/…/…/lib/’); though i think this has nothing to do with stylus.

well the problem above does.

i will debug / try what ever you want. just tell me what you want to know incase you dont have a windows test enviroment for this.

About this issue

  • Original URL
  • State: closed
  • Created 13 years ago
  • Comments: 28 (9 by maintainers)

Commits related to this issue

Most upvoted comments

@matthew-dean

How to deal with those files in node_modules ?

Should be fixed by glob@7.2.3. If it isn’t, please post a new issue at https://github.com/isaacs/node-glob/issues, ideally with a reproduction case. Thanks!

Problem with path C:\abrigo\new_projects\FusionD-docs\.vuepress\override.styl on Windows 10.

Workaround: Change new_projects to _new_projects, because \n creates new line in the import path.

Ok, my problem is related to #2680 : downgrading glob to v7.2.0 fixes the issue.