-
-
Notifications
You must be signed in to change notification settings - Fork 2.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Cannot catch spawnWorker() error outside #712
Comments
I was able to replicate what you describe, thanks for reporting this issue. I think this will require a patch to Tesseract.js to resolve.
This problem appears to be specific to Electron (which I believe VSCode uses), and does not occur in the browser. In addition to the fact that
|
Describe the bug
I am trying to use this great package to build a VS code extension, however it's weird that I cannot catch the error outside even if i wrapped try catch block outside or add catch block after the
createWorker
call.To Reproduce
Steps to reproduce the behavior:
activate
function code as followsdebug this extension
in the panel and type correspondingHello World
command in the test vscode window, then you can check the debug console you develop, it will print the logsThe logs only has 'before create worker', which means there is something wrong happens in the
createWorker()
.After the debugging, I found that it's because I didn't specify the
workerPath
which cause thespawnWorker()
function failed. However, I cannot catch the bugs outside, could anyone helps to look at if I am doing a wrong catch way?Expected behavior
Can catch the error outside.
The text was updated successfully, but these errors were encountered: