Call retries were exceeded - WorkerError (pdf.js)
Answered
yoconn posted this in #help-forum
yoconnOP
Trying to import and use pdfjs-dist to parse a pdf into a text string. It works fine on localhost, but when i try and build it i get this error:
Error: Call retries were exceeded
at ChildProcessWorker.initialize (F:\GitHub\project\node_modules\next\dist\compiled\jest-worker\index.js:1:11661)
at ChildProcessWorker._onExit (F:\GitHub\project\node_modules\next\dist\compiled\jest-worker\index.js:1:12599)
at ChildProcess.emit (node:events:514:28)
at ChildProcess.emit (node:domain:489:12)
at ChildProcess._handle.onexit (node:internal/child_process:291:12) {
type: 'WorkerError'
my import statement:
import * as pdfjsLib from 'pdfjs-dist/build/pdf';
If i comment that out it builds fine. I've tried setting the GlobalWorkerOptions I've seen recommended elsewhere for other issues but it all results in the same build error.
I'm not fully commited to pdfjs so if you have an alternative that works I'm up for it.
Thanks in advance
Error: Call retries were exceeded
at ChildProcessWorker.initialize (F:\GitHub\project\node_modules\next\dist\compiled\jest-worker\index.js:1:11661)
at ChildProcessWorker._onExit (F:\GitHub\project\node_modules\next\dist\compiled\jest-worker\index.js:1:12599)
at ChildProcess.emit (node:events:514:28)
at ChildProcess.emit (node:domain:489:12)
at ChildProcess._handle.onexit (node:internal/child_process:291:12) {
type: 'WorkerError'
my import statement:
import * as pdfjsLib from 'pdfjs-dist/build/pdf';
If i comment that out it builds fine. I've tried setting the GlobalWorkerOptions I've seen recommended elsewhere for other issues but it all results in the same build error.
I'm not fully commited to pdfjs so if you have an alternative that works I'm up for it.
Thanks in advance
Answered by yoconn
Turns out it was how I was handling cookies.
It was just a weird coincidence that when I commented out the import it built fine.
It was just a weird coincidence that when I commented out the import it built fine.
1 Reply
yoconnOP
Turns out it was how I was handling cookies.
It was just a weird coincidence that when I commented out the import it built fine.
It was just a weird coincidence that when I commented out the import it built fine.
Answer