@@ -43,6 +43,7 @@ import {
4343 startConversationCleanup ,
4444 stopConversationCleanup ,
4545} from './modules/ai.js' ;
46+ import { startBotStatus , stopBotStatus } from './modules/botStatus.js' ;
4647import { getConfig , loadConfig } from './modules/config.js' ;
4748import { registerEventHandlers } from './modules/events.js' ;
4849import { startGithubFeed , stopGithubFeed } from './modules/githubFeed.js' ;
@@ -54,7 +55,6 @@ import { startScheduler, stopScheduler } from './modules/scheduler.js';
5455import { startTriage , stopTriage } from './modules/triage.js' ;
5556import { startVoiceFlush , stopVoiceFlush } from './modules/voice.js' ;
5657import { fireEventAllGuilds } from './modules/webhookNotifier.js' ;
57- import { closeRedisClient as closeRedis , initRedis } from './redis.js' ;
5858import { pruneOldLogs } from './transports/postgres.js' ;
5959import { stopCacheCleanup } from './utils/cache.js' ;
6060import {
@@ -318,6 +318,7 @@ async function gracefulShutdown(signal) {
318318 stopScheduler ( ) ;
319319 stopGithubFeed ( ) ;
320320 perfMonitor . stop ( ) ;
321+ stopBotStatus ( ) ;
321322 stopVoiceFlush ( ) ;
322323
323324 // 1.5. Stop API server (drain in-flight HTTP requests before closing DB)
@@ -532,6 +533,9 @@ async function startup() {
532533 await loadCommands ( ) ;
533534 await client . login ( token ) ;
534535
536+ // Start bot status/activity rotation (runs after login so client.user is available)
537+ startBotStatus ( client ) ;
538+
535539 // Set Sentry context now that we know the bot identity (no-op if disabled)
536540 import ( './sentry.js' )
537541 . then ( ( { Sentry, sentryEnabled } ) => {
0 commit comments