From 7ceddcded643432f0f4b78aa22de7ad107b61f3a Mon Sep 17 00:00:00 2001 From: Re-bin Date: Wed, 11 Mar 2026 08:04:14 +0000 Subject: [PATCH] fix(wecom): await async disconnect, add SDK attribution in README --- README.md | 7 +++---- nanobot/channels/wecom.py | 2 +- 2 files changed, 4 insertions(+), 5 deletions(-) diff --git a/README.md b/README.md index 6e8211e..2a49214 100644 --- a/README.md +++ b/README.md @@ -681,7 +681,9 @@ nanobot gateway
Wecom (企业微信) -Uses **WebSocket** long connection — no public IP required. +> Here we use [wecom-aibot-sdk-python](https://github.com/chengyongru/wecom_aibot_sdk) (community Python version of the official [@wecom/aibot-node-sdk](https://www.npmjs.com/package/@wecom/aibot-node-sdk)). +> +> Uses **WebSocket** long connection — no public IP required. **1. Install the optional dependency** @@ -714,9 +716,6 @@ Go to the WeCom admin console → Intelligent Robot → Create Robot → select nanobot gateway ``` -> [!TIP] -> WeCom uses WebSocket to receive messages — no webhook or public IP needed! -
## 🌐 Agent Social Network diff --git a/nanobot/channels/wecom.py b/nanobot/channels/wecom.py index 1c44451..72be9e2 100644 --- a/nanobot/channels/wecom.py +++ b/nanobot/channels/wecom.py @@ -98,7 +98,7 @@ class WecomChannel(BaseChannel): """Stop the WeCom bot.""" self._running = False if self._client: - self._client.disconnect() + await self._client.disconnect() logger.info("WeCom bot stopped") async def _on_connected(self, frame: Any) -> None: