1

I looked for the similar questions; The error message "There are no input files to process" from jsdoc

Underscore character in filename was problem in that situation. But I have no underscore char.

My code is below;

var files = fs.readdirSync(dir);
for (var i=0; i < files.length; i++){
  if(files[i]){
    parse({src: dir + files[i]}).on('data', function (chunk) {
        db.collection("parsing").insert({data: JSON.parse(chunk)});
    });
  }
}

But sometimes this code throws me error as;

events.js:154
  throw er; // Unhandled 'error' event
  ^

JSDOC_ERROR: There are no input files to process.
at Explain.verifyOutput (/node_modules/jsdoc-api/lib/jsdoc-command.js:108:19)
at ChildProcess.<anonymous> (/node_modules/jsdoc-api/lib/explain.js:48:38)
at emitTwo (events.js:100:13)
at ChildProcess.emit (events.js:185:7)
at maybeClose (internal/child_process.js:850:16)
at Socket.<anonymous> (internal/child_process.js:323:11)
at emitOne (events.js:90:13)
at Socket.emit (events.js:182:7)
at Pipe._onclose (net.js:477:12)
Process finished with exit code 1

I control whether there is a file and then try to parse it. You can see from if(files[i]){} part. Why it says There are no input files to process.

How can I solve this? What can be the problem?

Community
  • 1
  • 1
mvrht
  • 11
  • 4

0 Answers0