You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
binding.open(pathModule._makeLong(path),
^
TypeError: path must be a string
at TypeError (native)
at Object.fs.open (fs.js:491:11)
at Object.fs.readFile (fs.js:262:6)
at C:\node_modules\node-tesseract\lib\tesseract.js:90:12
is anyone can help to figure out what's problem?
The text was updated successfully, but these errors were encountered:
Can you post a bit more of the source code, at least the rest of the parameters, there isn't much to go on...but it looks like path isn't a string and open() expects it to be.
Same issue here. I can't generate a consistent reproduction case but it sometimes happen in my production application, and it crashes the process. It seems that the files variable here is an empty array. That could happen only if tesseract fails and doesn't output any file.
The problem here is that this cannot be controlled by the application using the module. It can't even be try-catched. There should be a check for truthy-ness when passing files[0] to fs.readFile.
binding.open(pathModule._makeLong(path),
^
TypeError: path must be a string
at TypeError (native)
at Object.fs.open (fs.js:491:11)
at Object.fs.readFile (fs.js:262:6)
at C:\node_modules\node-tesseract\lib\tesseract.js:90:12
is anyone can help to figure out what's problem?
The text was updated successfully, but these errors were encountered: