mirror of
https://github.com/MindWorkAI/AI-Studio.git
synced 2025-04-27 22:59:47 +00:00
Improve error logging for invalid plugins by including the first issue in the message
This commit is contained in:
parent
9cf4f943fb
commit
9ddcf448c6
@ -113,13 +113,13 @@ public static partial class PluginFactory
|
||||
LOG.LogError($"Was not able to load plugin: '{pluginMainFile}'. Reason: Unknown.");
|
||||
continue;
|
||||
|
||||
case { IsValid: false }:
|
||||
LOG.LogError($"Was not able to load plugin '{pluginMainFile}', because the Lua code is not a valid AI Studio plugin. There are {plugin.Issues.Count()} issues to fix.");
|
||||
#if DEBUG
|
||||
foreach (var pluginIssue in plugin.Issues)
|
||||
LOG.LogError($"Plugin issue: {pluginIssue}");
|
||||
#endif
|
||||
continue;
|
||||
case { IsValid: false }:
|
||||
LOG.LogError($"Was not able to load plugin '{pluginMainFile}', because the Lua code is not a valid AI Studio plugin. There are {plugin.Issues.Count()} issues to fix. First issue is: {plugin.Issues.FirstOrDefault()}");
|
||||
#if DEBUG
|
||||
foreach (var pluginIssue in plugin.Issues)
|
||||
LOG.LogError($"Plugin issue: {pluginIssue}");
|
||||
#endif
|
||||
continue;
|
||||
|
||||
case { IsMaintained: false }:
|
||||
LOG.LogWarning($"The plugin '{pluginMainFile}' is not maintained anymore. Please consider to disable it.");
|
||||
|
Loading…
Reference in New Issue
Block a user