From 37b36b9a761754b7808f5c6bfac556b6fe8651f6 Mon Sep 17 00:00:00 2001 From: Leon Friedrich <60421075+ElectroJr@users.noreply.github.com> Date: Mon, 17 Oct 2022 04:58:07 +1300 Subject: [PATCH] Construction logging (#11961) --- Content.Server/Construction/ConstructionSystem.Graph.cs | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/Content.Server/Construction/ConstructionSystem.Graph.cs b/Content.Server/Construction/ConstructionSystem.Graph.cs index 210a21bf96..8b5b783d7a 100644 --- a/Content.Server/Construction/ConstructionSystem.Graph.cs +++ b/Content.Server/Construction/ConstructionSystem.Graph.cs @@ -268,7 +268,11 @@ namespace Content.Server.Construction ContainerManagerComponent? containerManager = null) { if (!Resolve(uid, ref construction, ref metaData, ref transform)) - return null; + { + // Failed resolve logs an error, but we want to actually log information about the failed construction + // graph. So lets let the UpdateInteractions() try-catch log that info for us. + throw new Exception("Missing construction components"); + } if (newEntity == metaData.EntityPrototype?.ID || !_prototypeManager.HasIndex(newEntity)) return null;