Closed gkatsev closed 10 years ago
Specifically, I receive the following errors:
Database error: Error: near line 13: no such table: movies
module.js:340
throw err;
^
Error: Cannot find module '/media/Media'
at Function.Module._resolveFilename (module.js:338:15)
at Function.Module._load (module.js:280:25)
at Function.Module.runMain (module.js:497:10)
at startup (node.js:119:16)
at node.js:902:3
Metadata fetching for movie complete...
Child process exited for: movie
Metadata fetcher error: { [Error: Command failed:
module.js:340
throw err;
^
Error: Cannot find module '/media/Media'
at Function.Module._resolveFilename (module.js:338:15)
at Function.Module._load (module.js:280:25)
at Function.Module.runMain (module.js:497:10)
at startup (node.js:119:16)
at node.js:902:3
] killed: false, code: 8, signal: null }
Database error: Error: near line 15: no such table: movies
Could not index any movies, please check given movie collection path
Changing console.error
to throw new Error
, I was able to find out specifically where the db error is occuring:
/media/Media A/Documents/projects/mediacenterjs/apps/movies/movie-functions.js:18
db.on('error', function (err) { throw new Error('Database error: ' + err) });
^
Error: Database error: Error: near line 1: no such table: movies
at EventEmitter.exports.loadItems.db.query.original_name (/media/Media A/Documents/projects/mediacenterjs/apps/movies/movie-functions.js:18:39)
at EventEmitter.emit (events.js:95:17)
at Socket.onerror (/media/Media A/Documents/projects/mediacenterjs/node_modules/dblite/build/dblite.node.js:228:12)
at Socket.EventEmitter.emit (events.js:95:17)
at Socket.<anonymous> (_stream_readable.js:746:14)
at Socket.EventEmitter.emit (events.js:92:17)
at emitReadable_ (_stream_readable.js:408:10)
at emitReadable (_stream_readable.js:404:5)
at readableAddChunk (_stream_readable.js:165:9)
at Socket.Readable.push (_stream_readable.js:127:10)
After more investigation, it's because of this line. There we try to exec the movie metadata js in a child but the path has a space in it. The beginning of a fix is to escape the spaces before calling exec.
Hej Gary,
Thanks for reporting this issue and investigating so thoroughly! I really appreciate it. I will definitely get going on the fix asap. I'll keep you posted of course.
Thanks again!
I think I have a fix, also!
I have all my media in the following paths:
Unfortunately, when it tries to scan the folder, it fails because it's trying to scan
/media/Media
.