Open azartheen opened 2 years ago
I am also facing the same issue after scanning QR Code
I am also facing same issue..
I got the solution. Do two things for this.
"whatsapp-web.js": "latest"
package-lock.json
file from node app folderThanks Usman Max for the help. @max-programming
Getting this error Now
lastqr/60last.qr generated
/var/www/html/WhatsappCode/node_modules/puppeteer/lib/cjs/puppeteer/common/DOMWorld.js:513
const timeoutError = new Errors_js_1.TimeoutError(waiting for ${options.title} failed: timeout ${options.timeout}ms exceeded
);
^
TimeoutError: waiting for selector canvas
failed: timeout 45000ms exceeded
at new WaitTask (/var/www/html/WhatsappCode/node_modules/puppeteer/lib/cjs/puppeteer/common/DOMWorld.js:513:34)
at DOMWorld.waitForSelectorInPage (/var/www/html/WhatsappCode/node_modules/puppeteer/lib/cjs/puppeteer/common/DOMWorld.js:424:26)
at Object.internalHandler.waitFor (/var/www/html/WhatsappCode/node_modules/puppeteer/lib/cjs/puppeteer/common/QueryHandler.js:31:77)
at DOMWorld.waitForSelector (/var/www/html/WhatsappCode/node_modules/puppeteer/lib/cjs/puppeteer/common/DOMWorld.js:317:29)
at Frame.waitForSelector (/var/www/html/WhatsappCode/node_modules/puppeteer/lib/cjs/puppeteer/common/FrameManager.js:841:51)
at Page.waitForSelector (/var/www/html/WhatsappCode/node_modules/puppeteer/lib/cjs/puppeteer/common/Page.js:2313:33)
at Timeout.getQrCode (/var/www/html/WhatsappCode/node_modules/whatsapp-web.js/src/Client.js:143:28)
at runMicrotasks (
whatsapp-node-api@0.0.3 start
puppeteer\lib\cjs\puppeteer\common\ExecutionContext.js:217 throw new Error('Evaluation failed: ' + helper_js_1.helper.getExceptionMessage(exceptionDetails)); ^
Error: Evaluation failed: TypeError: Cannot read property 'serialize' of undefined at puppeteer_evaluation_script:2:38 at ExecutionContext._evaluateInternal (C:\Users\Administrator\Downloads\Whatsapp_API\node_modules\puppeteer\lib\cjs\puppeteer\common\ExecutionContext.js:217:19) at processTicksAndRejections (node:internal/process/task_queues:96:5) at async ExecutionContext.evaluate (C:\Users\Administrator\Downloads\Whatsapp_API\node_modules\puppeteer\lib\cjs\puppeteer\common\ExecutionContext.js:106:16) at async Client.initialize (C:\Users\Administrator\Downloads\Whatsapp_API\node_modules\whatsapp-web.js\src\Client.js:184:42)
any idea why it is happening.. or else I did the wrong method???
@pranavms13 please give a cmt on this