Merge remote-tracking branch 'origin/dev/v3-testing' into dev/v3-testing

This commit is contained in:
Neil Dorin 2026-05-01 14:44:52 -06:00
commit b0525b0f97

View file

@ -1,7 +1,10 @@
using System; using System;
using System.Collections.Generic;
using System.IO.Compression; using System.IO.Compression;
using System.Linq; using System.Linq;
using System.Reflection; using System.Reflection;
using System.Threading;
using System.Threading.Tasks;
using Crestron.SimplSharp; using Crestron.SimplSharp;
using Crestron.SimplSharp.CrestronIO; using Crestron.SimplSharp.CrestronIO;
using Crestron.SimplSharpPro; using Crestron.SimplSharpPro;
@ -12,14 +15,11 @@ using PepperDash.Core.Adapters;
using PepperDash.Essentials.Core; using PepperDash.Essentials.Core;
using PepperDash.Essentials.Core.Bridges; using PepperDash.Essentials.Core.Bridges;
using PepperDash.Essentials.Core.Config; using PepperDash.Essentials.Core.Config;
using PepperDash.Essentials.Core.Routing;
using System.Threading;
using Timeout = Crestron.SimplSharp.Timeout;
using Serilog.Events;
using System.Threading.Tasks;
using PepperDash.Essentials.Core.Web;
using System.Collections.Generic;
using PepperDash.Essentials.Core.DeviceTypeInterfaces; using PepperDash.Essentials.Core.DeviceTypeInterfaces;
using PepperDash.Essentials.Core.Routing;
using PepperDash.Essentials.Core.Web;
using Serilog.Events;
using Timeout = Crestron.SimplSharp.Timeout;
namespace PepperDash.Essentials; namespace PepperDash.Essentials;
@ -506,9 +506,13 @@ public class ControlSystem : CrestronControlSystem, ILoadConfig, IInitialization
new Core.Monitoring.SystemMonitorController("systemMonitor")); new Core.Monitoring.SystemMonitorController("systemMonitor"));
} }
if (ConfigReader.ConfigObject is not null) if (ConfigReader.ConfigObject is null)
{ {
Debug.LogMessage(LogEventLevel.Warning, "LoadDevices: ConfigObject is null. Cannot load devices."); Debug.LogMessage(LogEventLevel.Warning, "LoadDevices: ConfigObject is null. Cannot load devices.");
return;
}
Debug.LogInformation("Loading devices from config.");
foreach (var devConf in ConfigReader.ConfigObject.Devices) foreach (var devConf in ConfigReader.ConfigObject.Devices)
{ {
@ -549,10 +553,11 @@ public class ControlSystem : CrestronControlSystem, ILoadConfig, IInitialization
Debug.LogMessage(e, "ERROR: Creating device {deviceKey:l}. Skipping device.", args: new[] { devConf.Key }); Debug.LogMessage(e, "ERROR: Creating device {deviceKey:l}. Skipping device.", args: new[] { devConf.Key });
} }
} }
}
Debug.LogMessage(LogEventLevel.Information, "All Devices Loaded."); Debug.LogMessage(LogEventLevel.Information, "All Devices Loaded.");
return;
} }