Files
moltbot/extensions
IVY 5adf9d2619 fix(discord): prevent identify race (#68159)
Verified against Carbon 0.16.0 source:
- Client constructor calls plugin.registerClient(this) without awaiting it.
- GatewayPlugin.registerClient publishes client before its awaited metadata fetch.
- identify() silently returns when client is missing.

This patch matches Carbon's ordering in OpenClaw's subclass, avoids a second super.registerClient call if lifecycle connect already opened the socket during metadata loading, and keeps regression coverage for both ws and isConnecting cases.

Local proof:
- pnpm test extensions/discord/src/monitor/provider.proxy.test.ts extensions/discord/src/monitor/gateway-plugin.test.ts
- pnpm lint:tmp:no-raw-channel-fetch
- pnpm check:changed
- pnpm check
- pnpm test

GitHub checks green for 72547825e1.
2026-04-24 22:39:44 +01:00
..
2026-04-20 13:16:40 +01:00
2026-04-20 13:16:40 +01:00
2026-04-20 13:16:40 +01:00
2026-04-24 15:12:37 +01:00
2026-04-20 13:16:40 +01:00
2026-04-20 13:16:40 +01:00
2026-04-20 13:16:40 +01:00
2026-04-23 04:00:17 +01:00
2026-04-20 13:16:40 +01:00
2026-04-20 13:16:40 +01:00
2026-04-20 13:16:40 +01:00
2026-04-20 13:16:40 +01:00
2026-04-20 13:16:40 +01:00
2026-04-20 16:34:48 +01:00
2026-04-20 13:16:40 +01:00
2026-04-24 16:07:53 +01:00