[BUG] Baileys session stops receiving inbound messages while dashboard still shows "Connected" — requires full container restart to recover
Maintainers usually reply within 4 days
Nobody has claimed this yet.
Assessment
- Difficulty
- 5/5
- Estimated time
- Over a week
- Newbie friendliness
- 30/100
- Issue type
- Bug
- Clarity
- Mostly clear
- Activity status
- Active
- Tech stack
- docker, postgresql, redis, typescript
Research direction
Start by tracing the Baileys session lifecycle and the ChannelStartupService connection logs; the payload does not name source files or tests. Compare how inbound message events update the chat/message store with how outbound sends and the dashboard connection status are reported. The issue is resolved when inbound messages resume reliably after recovery and the reported status reflects a stalled session.
Written by the indexing model from the issue text.
Description
📋 Bug Description
The WhatsApp (Baileys) session silently stops receiving new inbound messages while the Evolution Manager dashboard and the instance status both continue to report "Connected". Outbound sends (messages triggered by our own automation via the API) continue to work normally during the stall, which masks the problem and makes it hard to detect from the dashboard alone. The only reliable fix found so far is a full restart of the evolution-api container (not the in-app “Restart”/”Disconnect” buttons in Evolution Manager, which do not recover the session once it’s already stalled).
🔄 Steps to Reproduce
This appears to happen spontaneously after some hours of uptime (not tied to a specific user action). Observed recurrence: 3 times in under 48 hours.
Instance connects normally and processes inbound/outbound messages for some hours.
At some point, inbound messages stop being written to the instance’s message/chat store (findChats / findMessages), even though:
The dashboard still shows the instance as "Connected".
Outbound messages sent via our own API calls are still delivered and logged correctly (fromMe: true records keep appearing).
Using Evolution Manager’s own in-app “Restart” and “Disconnect” buttons does not recover message reception.
A full restart of the underlying Docker container (outside Evolution Manager, at the hosting/orchestration level) does recover it — confirmed via a new [ChannelStartupService] CONNECTED TO WHATSAPP log line and fresh inbound messages syncing in afterward.
The issue recurred again ~16.5 hours after the first fix, and a third time a few hours after the second restart — this time, even after the container restart logged CONNECTED TO WHATSAPP, inbound sync did not resume at all (verified directly against the instance’s own chat/message database: the most recently updated chat across the entire instance remained stuck ~9+ hours in the past, with zero new records, despite test messages sent and outbound automation continuing to fire).
✅ Expected Behavior
The instance should either genuinely reflect a disconnected/degraded state (not "Connected") when the Baileys session stops receiving events, so monitoring can catch it, and/or
The in-app Restart/Disconnect actions should reliably force a real reconnect without requiring an external container restart, and/or
A full container restart should reliably restore inbound message reception (this was not the case the third time).
❌ Actual Behavior
The Baileys session stops receiving new inbound WhatsApp messages while the instance dashboard and status endpoint still report "Connected". Outbound messages sent via our own API/automation continue to work and get logged normally (fromMe: true records keep appearing), which masks the failure.
Confirmed directly against the instance’s own database (/chat/findChats and /chat/findMessages): the most recently updated chat across the entire instance was stuck more than 9 hours in the past, with zero new inbound records, even though test messages were sent during that window and outbound automation kept firing normally.
Evolution Manager’s own in-app “Restart” and “Disconnect” buttons did not recover inbound reception. A full restart of the underlying Docker container did recover it the first time (new [ChannelStartupService] CONNECTED TO WHATSAPP log line, followed by inbound messages syncing again), but on a later occurrence, even a full container restart with that same “CONNECTED TO WHATSAPP” log line did not restore inbound message reception — the instance kept reporting “Connected” with zero new inbound activity afterward.
This has now happened 3 times in under 48 hours.
🌍 Environment
Evolution API, self-hosted via Docker (EasyPanel), with Postgres + Redis.
WhatsApp connector: Baileys, version observed in logs: 2.3000.1054337431.
Instance driven by n8n via real-time Webhook + a periodic flush/schedule trigger.
📋 Logs
📝 Additional Context
Happy to share more detailed timestamps/logs if useful — this is a production instance for a small business’s customer-service WhatsApp bot, so the silent nature of the failure (dashboard shows healthy) is the most damaging part, since it delays detection.
- Dominant language
- TypeScript
- Stars
- 10.2k
- Forks
- 7.5k
- Avg merge
- 6d 19h
- Merged PRs (30d)
- 4
Getting set up
- Ships a Dockerfile or Docker Compose file
- Has a pull request template
- Read the contributing guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from evolution-foundation/evolution-api
-
Difficulty 2/5 1-3 hours Newbie friendliness 76/100
evolution-foundation/evolution-api#2796 ·
Maintainers usually reply within 4 days
-
Difficulty 2/5 1-3 hours Newbie friendliness 76/100
evolution-foundation/evolution-api#2795 ·
Maintainers usually reply within 4 days
-
Difficulty 2/5 1-3 hours Newbie friendliness 76/100
evolution-foundation/evolution-api#2782 ·
Maintainers usually reply within 4 days
-
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
evolution-foundation/evolution-api#2723 ·
Maintainers usually reply within 4 days
-
Difficulty 1/5 1-3 hours Newbie friendliness 88/100
evolution-foundation/evolution-api#2704 ·
Maintainers usually reply within 4 days
All issues in evolution-foundation/evolution-api
Similar issues
-
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
abhigyanpatwari/GitNexus#4124 ·
Maintainers usually reply within 1 day
-
good first issue
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
laaielichter/Godotwright#250 ·
Maintainers usually reply within 1 day
-
An Antigravity tab can quote an old Assist message as the owner's words in a resumed conversationOpen
Difficulty 2/5 1-3 hours Newbie friendliness 62/100
Maintainers usually reply within 1 day
-
Retry an empty final answer when Gemini reports MALFORMED_RESPONSE (gemini-4-hydrogen)Possibly taken @waleedkadous claimed this today. Open
Difficulty 2/5 1-3 hours Newbie friendliness 62/100
iaser-ai/ansari#444 · 1 comment ·
Maintainers usually reply within 1 day
-
[Bug]: Manager UI logo fails to load — broken external URLPossibly taken @kavindu-udara claimed this today. Openbug
Difficulty 2/5 1-3 hours Newbie friendliness 68/100