Skip to content

[macOS][Agent&Skills] channels remove whatsapp does not teardown Baileys session or remove whatsapp policy preset — channel stays active after rebuild #3998

@mercl-lau

Description

@mercl-lau

Description

After running nemoclaw test333 channels remove whatsapp and completing the rebuild, the WhatsApp channel continues to function — the AI agent still receives and responds to incoming WhatsApp DMs. Three cleanup steps are missing: policy preset removal, Baileys session teardown, and durable state directory cleanup.

Environment

Device:        MacBook Pro (Apple Silicon)
OS:            macOS 26.0.1 (Darwin 25.0.0, arm64)
Architecture:  arm64
Node.js:       v22.22.1
npm:           10.9.4
Docker:        29.2.1
OpenShell CLI: 0.0.39
NemoClaw:      v0.0.48
OpenClaw:      2026.4.24 (cbcfdf6)

Steps to Reproduce

  1. nemoclaw onboard --name test333 (complete onboard with NVIDIA Cloud API)
  2. nemoclaw test333 channels add whatsapp (add WhatsApp channel, answer y to rebuild)
  3. nemoclaw test333 connectopenclaw channels login --channel whatsapp (complete QR pairing, confirm channels status shows connected)
  4. Exit sandbox
  5. nemoclaw test333 channels remove whatsapp (answer y to rebuild)
  6. cat ~/.nemoclaw/sandboxes.json | python3 -c "import json,sys; d=json.load(sys.stdin); print(d['sandboxes']['test333']['messagingChannels'])"
  7. nemoclaw test333 policy-list
  8. nemoclaw test333 connectopenclaw channels status
  9. Send a WhatsApp DM to the paired phone number

Expected Result

  • Step 6: messagingChannels = [] (channel unregistered)
  • Step 7: whatsapp preset absent from policy-list (symmetric with channels add which auto-applies it)
  • Step 8: No WhatsApp channel shown in openclaw channels status
  • Step 9: No AI response — channel fully deactivated after removal

Actual Result

  • Step 6: messagingChannels = [] — registry cleared correctly
  • Step 7: whatsapp preset STILL ACTIVE in policy-list (● whatsapp shown)
  • Step 8: No WhatsApp channel listed in openclaw channels status (misleading — appears removed)
  • Step 9: AI agent STILL REPLIES to WhatsApp DMs — channel is fully functional despite removal

Logs

Post-rebuild log from nemoclaw test333 logs shows Baileys reconnecting:

ALLOWED /usr/local/bin/node(390) -> raw.githubusercontent.com:443 [policy:whatsapp engine:opa]
ALLOWED GET http://raw.githubusercontent.com:443/WhiskeySockets/Baileys/master/src/Defaults/index.ts [policy:whatsapp engine:l7]
ALLOWED /usr/local/bin/node(390) -> web.whatsapp.com:443 [policy:whatsapp engine:opa]

Rebuild output also confirms whatsapp preset reapplied during [8/8] Policy presets:

[resume] Reapplying policy presets: npm, pypi, huggingface, brew, whatsapp
Widening sandbox egress — adding: web.whatsapp.com, *.web.whatsapp.com, whatsapp.net, *.whatsapp.net, raw.githubusercontent.com
Applied preset: whatsapp

NVB#6200345

Metadata

Metadata

Assignees

Labels

NV QABugs found by the NVIDIA QA TeamUATIssues flagged for User Acceptance Testing.area: cliCommand line interface, flags, terminal UX, or outputintegration: whatsappWhatsApp integration or channel behaviorplatform: macosAffects macOS, including Apple Silicon

Type

No fields configured for Bug.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions