ProtocolError: Protocol error (Network.getResponseBody): Target closed.
at whatsapp-contact-sync/server/node_modules/puppeteer/src/common/Connection.ts:304:16
at new Promise (<anonymous>)
at CDPSession.send (whatsapp-contact-sync/server/node_modules/puppeteer/src/common/Connection.ts:300:12)
at whatsapp-contact-sync/server/node_modules/puppeteer/src/common/HTTPResponse.ts:192:47
at processTicksAndRejections (node:internal/process/task_queues:95:5)
at async HTTPResponse.text (whatsapp-contact-sync/server/node_modules/puppeteer/src/common/HTTPResponse.ts:220:21)
at async whatsapp-contact-sync/server/node_modules/whatsapp-web.js/src/Client.js:733:44 {
originalMessage: ''
This error also sometimes appear:
Error: Protocol error (Runtime.callFunctionOn): Session closed. Most likely the page has been closed.
at CDPSession.send (whatsapp-contact-sync/server/node_modules/puppeteer/src/common/Connection.ts:286:9)
at ExecutionContext._evaluateInternal (whatsapp-contact-sync/server/node_modules/puppeteer/src/common/ExecutionContext.ts:254:44)
at ExecutionContext.evaluate (whatsapp-contact-sync/server/node_modules/puppeteer/src/common/ExecutionContext.ts:140:23)
at DOMWorld.evaluate (whatsapp-contact-sync/server/node_modules/puppeteer/src/common/DOMWorld.ts:174:20)
Bug appears when performing these actions:
This error causes the backend to crash.
Full error:
This error also sometimes appear: