You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Some events are missing, looks like a race condition issue. I've tested with 1 business account, 1 personal account and another 2 numbers (these 2 numbers didn't triggered this issue). It's not clear when this happen, but it's happening!
Environment
WPPConnect version(s): 1.34.1
WA-JS version(s): 3.10.1
Browser: Chrome Version 128.0.6613.138 (Official Build) (arm64)
After having a existing session and connected, terminate the process and send 15 messages and then run the process again to start receiving the messages while it was disconnected.
When I sent 9 messages, in this case, first 1-4 messages normally are lost.
In this case, messages with body 1, 2, 3 were lost
debug: [manfe:client] Emitting onAnyMessage event (1 registered)
New Message: 4
debug: [manfe:client] Emitting onAnyMessage event (1 registered)
New Message: 5
debug: [manfe:client] Emitting onAnyMessage event (1 registered)
New Message: 6
debug: [manfe:client] Emitting onAnyMessage event (1 registered)
New Message: 7
debug: [manfe:client] Emitting onAnyMessage event (1 registered)
New Message: 8
debug: [manfe:client] Emitting onAnyMessage event (1 registered)
New Message: 9
So I started debugging and I noticed that listener.layer.js is being injected/called after WA.js is already emiting some events for `u.MsgStore.on("add", (e) => {})
But if I add a console.log to the WA.js inside the function when the add is emitted I see the missing messages as isNewMsg.
The text was updated successfully, but these errors were encountered:
Description
Some events are missing, looks like a race condition issue. I've tested with 1 business account, 1 personal account and another 2 numbers (these 2 numbers didn't triggered this issue). It's not clear when this happen, but it's happening!
Environment
Steps to Reproduce
create a regular session, my code:
After having a existing session and connected, terminate the process and send 15 messages and then run the process again to start receiving the messages while it was disconnected.
When I sent 9 messages, in this case, first 1-4 messages normally are lost.
In this case, messages with body
1
,2
,3
were lostSo I started debugging and I noticed that
listener.layer.js
is being injected/called after WA.js is already emiting some events for `u.MsgStore.on("add", (e) => {})But if I add a
console.log
to the WA.js inside the function when theadd
is emitted I see the missing messages asisNewMsg
.The text was updated successfully, but these errors were encountered: