Repository navigation
Atualiza para 2.3.8 + backport (LID/9º dígito, reply-quote, group history bundle) - #1
Merged
Merged
Conversation
WhatsApp now sends <status> stanzas to linked devices and expects an ack.
Baileys 7.0.0-rc.9 drops them unacknowledged, so the server ends the stream
("stream errored out", ack class=status) and the instance reconnects in a
state where it stays "open" but stops receiving messages.
Patch Baileys via patch-package to ack <status> both online (CB:status) and
in the offline node queue. The Docker builder copies patches/ before npm ci
so the postinstall hook applies it in the image.
…n/hotfix/baileys-status-ack fix(baileys): ack incoming status stanzas
In rc.9 the offline node loop awaits each handler without a catch, so a failed status ack ended the loop with isProcessing still set and no later offline node was processed until the socket reconnected.
…n/fix/baileys-status-ack-offline-queue fix(baileys): keep the offline queue running when a status ack fails
…n/release/2.3.8-baileys-status chore(release): 2.3.8
…bundle fixes Backport of three upstream PRs onto 2.3.8, scoped to the live (messages.upsert) path that this fork actually uses: - evolution-foundation#2688: fix Brazilian 9th-digit handling in formatBRNumber / onWhatsappCache / numberJid resolution, and keep 13-digit BR JIDs from being downgraded to 12. - evolution-foundation#2708: preserve reply/quote contextInfo when flattening extendedTextMessage, and take the sender from the message key (not the quoted author's participant). - evolution-foundation#2663 (live path only): resolve @lid -> phone JID BEFORE the chat lookup, the message row and the media path, so persisted rows are keyed by the phone number instead of the hidden lid. The develop history-sync portion is not ported (2.3.8 has a different messaging-history.set and HISTORIC is off in production). - evolution-foundation#2808: decryptGroupHistoryBundle util (node:crypto/zlib + baileys proto, SHA-256 + constant-time MAC verified before decrypt, size caps) and a background processGroupHistoryBundle that replays a group "share recent messages" bundle through the existing messaging-history.set. Adapted to 2.3.8's handler. Nivel 2 (evolution-foundation#2612/evolution-foundation#2732) intentionally NOT ported: the 408-as-logout bug they fix does not exist in 2.3.8 (408 is not in codesToNotReconnect; it was introduced in 2.4.0/develop). Verified: tsc --noEmit clean, eslint clean on changed files, npm run build OK. NOT yet tested against a live instance. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
O que esta PR faz
Atualiza o fork para Evolution API 2.3.8 (merge de
upstream/main) e faz o backport, para o caminho ao vivo (messages.upsert), de três correções de upstream relevantes para o Radar de Ingressos. Tudo numa PR combinada.Nível 1 — número correto e vínculo da procura
formatBRNumber/onWhatsappCache/ resolução denumberJid; evita rebaixar JID de 13 dígitos para 12.contextInfode reply/quote ao achatarextendedTextMessage;pushNamepassa a vir da chave da mensagem (não do autor citado).@lid→ JID de telefone antes do lookup do chat, da linha gravada e do caminho de mídia, para que as linhas persistidas usem o número e não o lid oculto.Nível 3 — histórico de grupo
decryptGroupHistoryBundle(node:crypto/zlib+protodo Baileys; verifica SHA-256 e MAC em tempo constante antes de descriptografar, com tetos de tamanho) eprocessGroupHistoryBundleem segundo plano, que reentrega o bundle de "compartilhar mensagens recentes" pelomessaging-history.setexistente.O que NÃO foi portado (de propósito)
codesToNotReconnect; ele entrou na 2.4.0/develop). Portar seria corrigir um bug inexistente.messaging-history.setque só existe no develop; eDATABASE_SAVE_DATA_HISTORICfica desligado em produção).baileys+7.0.0-rc13.patchdo fix(baileys): resolve @lid to phone JID across history sync and live messages evolution-foundation/evolution-api#2663 (o fork usarc.9; é um fix de media-retry, não de LID).Verificação
tsc --noEmitlimpoeslintlimpo nos arquivos alteradosnpm run buildOK