Menu

#386 Cannot find module '.src/utils/ActionQueue.js'. Must be ./ in front of the path.

open
nobody
None
5
2013-01-15
2013-01-15
Jira Trac
No

You forgot to add slash in front of the require path.

{code}
var _CUBRIDConnection = require('./src/CUBRIDConnection.js');
var _Helpers = require('./src/utils/Helpers.js');
var _Result2Array = require('./src/resultset/Result2Array.js');
var _ActionQueue = require('.src/utils/ActionQueue.js');
{code}

Should be *'./src/...'* instead of *'.src/...'*.

Otherwise, it returns the following error:

{code}
module.js:340
throw err;
^
Error: Cannot find module '.src/utils/ActionQueue.js'
at Function.Module._resolveFilename (module.js:338:15)
at Function.Module._load (module.js:280:25)
at Module.require (module.js:362:17)
at require (module.js:378:17)
at Object.anonymous (/Users/nbp/repos/cubrid_nodejs_examples/node_modules/node-cubrid/index.js:4:20)
at Module._compile (module.js:449:26)
at Object.Module._extensions..js (module.js:467:10)
at Module.load (module.js:356:32)
at Function.Module._load (module.js:312:12)
at Module.require (module.js:362:17)

Process finished with exit code 1
{code}

*Remember to run tests before committing any change*.

Discussion

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.