WhiskeySockets / Baileys

Lightweight full-featured typescript/javascript WhatsApp Web API
https://baileys.whiskeysockets.io/
MIT License
4.03k stars 1.36k forks source link

Critical_block #1044

Open roysG opened 2 months ago

roysG commented 2 months ago

Describe the bug A clear and concise description of what the bug is.

To Reproduce Steps to reproduce the behavior:

  1. hold the connection for few days
  2. Suddenly you will get
  3. Expected behavior No error

Environment (please complete the following information):

Error logs:

Sep 17 04:51:56.032 whatsapp-5c8d96685-dst8m stdout: {"level":20,"time":"2024-09-17T01:51:55.663Z","pid":197,"hostname":"whatsapp-5c8d96685-dst8m","syncAction":{"syncAction":{"index":"WyJzZW50aW5lbCIsImNyaXRpY2FsX2Jsb2NrIl0=","value":{"timestamp":"1726537914853","keyExpiration":{"expiredKeyEpoch":57298}},"padding":"","version":3},"index":["sentinel","critical_block"]},"id":"critical_block","msg":"unprocessable update"} Sep 17 04:51:56.032 whatsapp-5c8d96685-dst8m processing sync action Sep 17 04:51:56.032 whatsapp-5c8d96685-dst8m unprocessable update Sep 17 04:51:56.032 whatsapp-5c8d96685-dst8m released buffered events Sep 17 04:51:56.032 whatsapp-5c8d96685-dst8m recv 70 bytes, total recv 70 bytes Sep 17 04:51:56.032 whatsapp-5c8d96685-dst8m recv frame Sep 17 04:51:56.032 whatsapp-5c8d96685-dst8m Sep 17 04:51:56.035 whatsapp-5c8d96685-dst8m stdout: events { Sep 17 04:51:56.035 whatsapp-5c8d96685-dst8m 'connection.update': { Sep 17 04:51:56.035 whatsapp-5c8d96685-dst8m connection: 'close', Sep 17 04:51:56.035 whatsapp-5c8d96685-dst8m lastDisconnect: { error: [Error], date: 2024-09-17T01:51:56.034Z } Sep 17 04:51:56.035 whatsapp-5c8d96685-dst8m } Sep 17 04:51:56.035 whatsapp-5c8d96685-dst8m } Sep 17 04:51:56.035 whatsapp-5c8d96685-dst8m Sep 17 04:51:56.035 whatsapp-5c8d96685-dst8m stdout: Connection closed. You are logged out.

stdout: {"level":10,"time":"2024-09-17T01:51:56.032Z","pid":197,"hostname":"whatsapp-5c8d96685-dst8m","xml":" </stream:error>","msg":"recv xml"} Sep 17 04:51:56.036 whatsapp-5c8d96685-dst8m stream errored out Sep 17 04:51:56.036 whatsapp-5c8d96685-dst8m connection errored Sep 17 04:51:56.036 whatsapp-5c8d96685-dst8m recv frame Sep 17 04:51:56.036 whatsapp-5c8d96685-dst8m recv xml Sep 17 04:51:56.036 whatsapp-5c8d96685-dst8m connection already closed

Fusseldieb commented 1 month ago

Just lost my number trying to use this library, for some reason. I paired it, sent a single message with "Test", and got banned instantly . Thinking of migrating to something else, at least for now...

bobslavtriev commented 1 month ago

Problem in your code, use it correctly as stated in the documentation.