Skip to content

Commit 777b831

Browse files
authored
fix(weixin_oc): add error handling and retry logic for inbound updates polling (#7041)
fixes: #7022
1 parent 383df74 commit 777b831

1 file changed

Lines changed: 7 additions & 0 deletions

File tree

astrbot/core/platform/sources/weixin_oc/weixin_oc_adapter.py

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -902,6 +902,13 @@ async def run(self) -> None:
902902
"weixin_oc(%s): inbound long-poll timeout",
903903
self.meta().id,
904904
)
905+
except Exception as e:
906+
logger.error(
907+
"weixin_oc(%s): poll inbound updates failed, will retry after 5 seconds: %s",
908+
self.meta().id,
909+
e,
910+
)
911+
await asyncio.sleep(5)
905912
except asyncio.CancelledError:
906913
raise
907914
except Exception as e:

0 commit comments

Comments
 (0)