Unable to send message after session restore
See original GitHub issueIs there an existing issue for this?
- I have searched the existing issues
Describe the bug
I am trying to restore session after the server restart. No exception comes while startup and restoration. I could see puppeteer using the right file where session details are saved but while sending message on old session it fails.
Evaluation failed: TypeError: chat.isEphemeralSettingOn is not a function at Object.window.WWebJS.sendMessage (__puppeteer_evaluation_script__:157:37)
Expected behavior
Message should go as usual.
Steps to Reproduce the Bug or Issue
- Run the whatsapp-web using LocalAuth
- Register a WhatsApp number by scanning QR code
- After registration is successful, test sending a message
- Kill the node server using Ctrl + C
- Start the server again
- Load the clients by token
- Send message for old client
- You get the error
Relevant Code
const client = new Client({ puppeteer: { handleSIGINT: false, headless: true, args: [‘–no-sandbox’, ‘–disable-setuid-sandbox’] }, // Make headless true or remove to run browser in background authStrategy: new LocalAuth({ clientId: token }), });
Browser Type
Chromium
WhatsApp Account Type
Standard
Does your WhatsApp account have multidevice enabled?
No, I am not using Multi Device
Environment
- Ubuntu 22.04 LTS
- whatsapp-web.js 1.16.7
- node v14.17.5
Additional context
No response
Issue Analytics
- State:
- Created a year ago
- Reactions:1
- Comments:17
Top Results From Across the Web
Help! "Session Expired" message and I've lost an
I just spent nearly 2 hours constructing an email that I have to send this morning, and suddenly I got a pop up...
Read more >How to Fix Session Has Expired Error on the Internet
If your Internet connection is unstable, periodically disconnecting and reconnecting, it can cause a website session to expire. When the ...
Read more >how to fix the session expired email?? - Gmail Community
It is best to ensure recovery attempts are made from the most recent/usual location involving the setup the system considers familiar and hence, ......
Read more >Resolving Session Time-Out Errors - Support Center
The Session Time-Out message is normally displayed after several hours have elapsed since your last interaction with the server. If this happens, you...
Read more >Why is my session expiring immediately after I log in to ...
If you are encountering a message, "Your session has expired. Please relogin" and are prompted to log back in with your email address...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Clearing session or clearing pupeteer user-data and login again fixed the problem
I also experience the same error.