Added a lot more error handling to the bot so issues retrieving tokens should no longer completely take the bot down. Also added a last ditch exit if the bot has completely died and isn't reconnecting at all

This commit is contained in:
barelyprofessional
2025-07-24 12:45:37 -05:00
parent f92cba5b49
commit 35c3964854
2 changed files with 88 additions and 12 deletions

View File

@@ -911,6 +911,22 @@ public static class BuiltIn
Default = "false",
ValueType = SettingValueType.Boolean,
Regex = "(true|false)"
},
new BuiltInSettingsModel
{
Key = Keys.BotDeadBotDetectionInterval,
Description = "Interval in seconds for checking if the bot is completely dead",
Default = "15",
ValueType = SettingValueType.Text,
Regex = @"\d+"
},
new BuiltInSettingsModel
{
Key = Keys.BotExitOnDeath,
Description = "Whether the bot should exit if it's dead and unrecoverable",
Default = "true",
ValueType = SettingValueType.Boolean,
Regex = "(true|false)"
}
];
@@ -1014,5 +1030,7 @@ public static class BuiltIn
public static string KiwiPeerTubeEnabled = "KiwiPeerTube.Enabled";
public static string KiwiPeerTubeCheckInterval = "KiwiPeerTube.CheckInterval";
public static string KiwiPeerTubeEnforceWhitelist = "KiwiPeerTube.EnforceWhitelist";
public static string BotDeadBotDetectionInterval = "Bot.DeadBotDetectionInterval";
public static string BotExitOnDeath = "Bot.ExitOnDeath";
}
}