whatsapp-api
whatsapp-api copied to clipboard
Puppeteer exception killing the App
When disconnecting the session from mobile phone, the app dies with the following message:
/usr/src/app/node_modules/puppeteer/lib/cjs/puppeteer/common/Connection.js:230
error: new Errors_js_1.ProtocolError(),
^
ProtocolError: Protocol error (Network.getResponseBody): Target closed.
at /usr/src/app/node_modules/puppeteer/lib/cjs/puppeteer/common/Connection.js:230:24
at new Promise (<anonymous>)
at CDPSession.send (/usr/src/app/node_modules/puppeteer/lib/cjs/puppeteer/common/Connection.js:226:16)
at /usr/src/app/node_modules/puppeteer/lib/cjs/puppeteer/common/HTTPResponse.js:128:57
at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
at async HTTPResponse.text (/usr/src/app/node_modules/puppeteer/lib/cjs/puppeteer/common/HTTPResponse.js:148:25)
at async /usr/src/app/node_modules/whatsapp-web.js/src/Client.js:757:44 {
originalMessage: ''
}
This happened using the container
and also when running through npm start
.
Its a random issue. Sometimes it disconnects normal and once in a while it just crashes.
Thanks for the help and good luck fixing it.
Cheers.