diff --git a/src/Tgstation.Server.Host/Components/Compiler/DreamMaker.cs b/src/Tgstation.Server.Host/Components/Compiler/DreamMaker.cs
index 17a66e4ed2..121d2b2871 100644
--- a/src/Tgstation.Server.Host/Components/Compiler/DreamMaker.cs
+++ b/src/Tgstation.Server.Host/Components/Compiler/DreamMaker.cs
@@ -176,7 +176,7 @@ namespace Tgstation.Server.Host.Components.Compiler
logger.LogDebug("DreamMaker exit code: {0}", exitCode);
job.Output = dm.GetCombinedOutput();
- logger.LogTrace("DreamMaker output: {0}", job.Output);
+ logger.LogTrace("DreamMaker output: {0}{1}", Environment.NewLine, job.Output);
return exitCode;
}
}
@@ -263,11 +263,7 @@ namespace Tgstation.Server.Host.Components.Compiler
lock (this)
{
if (Status != CompilerStatus.Idle)
- {
- job.Output = "There is already a compile in progress!";
- logger.LogInformation(job.Output);
- return job;
- }
+ throw new Exception("There is already a compile in progress!");
Status = CompilerStatus.Copying;
}
@@ -340,11 +336,7 @@ namespace Tgstation.Server.Host.Components.Compiler
logger.LogTrace("Searching for available .dmes...");
var path = (await ioManager.GetFilesWithExtension(dirA, DmeExtension, cancellationToken).ConfigureAwait(false)).FirstOrDefault();
if (path == default)
- {
- job.Output = "Unable to find any .dme!";
- logger.LogWarning(job.Output);
- return job;
- }
+ throw new Exception("Unable to find any .dme!");
var dmeWithExtension = ioManager.GetFileName(path);
job.DmeName = dmeWithExtension.Substring(0, dmeWithExtension.Length - DmeExtension.Length - 1);
}
diff --git a/src/Tgstation.Server.Host/Core/Process.cs b/src/Tgstation.Server.Host/Core/Process.cs
index 45750daeaa..cd869ee83a 100644
--- a/src/Tgstation.Server.Host/Core/Process.cs
+++ b/src/Tgstation.Server.Host/Core/Process.cs
@@ -50,7 +50,7 @@ namespace Tgstation.Server.Host.Core
{
if (combinedStringBuilder == null)
throw new InvalidOperationException("Output/Error reading was not enabled!");
- return combinedStringBuilder.ToString();
+ return combinedStringBuilder.ToString().TrimStart(Environment.NewLine.ToCharArray());
}
///
@@ -58,7 +58,7 @@ namespace Tgstation.Server.Host.Core
{
if (errorStringBuilder == null)
throw new InvalidOperationException("Error reading was not enabled!");
- return errorStringBuilder.ToString();
+ return errorStringBuilder.ToString().TrimStart(Environment.NewLine.ToCharArray());
}
///
@@ -66,7 +66,7 @@ namespace Tgstation.Server.Host.Core
{
if (outputStringBuilder == null)
throw new InvalidOperationException("Output reading was not enabled!");
- return errorStringBuilder.ToString();
+ return errorStringBuilder.ToString().TrimStart(Environment.NewLine.ToCharArray());
}
///
diff --git a/v4_prototype_TODO.txt b/v4_prototype_TODO.txt
index 572d75b123..b2ea1bbeca 100644
--- a/v4_prototype_TODO.txt
+++ b/v4_prototype_TODO.txt
@@ -1,3 +1,5 @@
Verify the byond cache folder location on linux
Test watchdog
+
+Add a JobException type that the job manager will just print the message of. Replace throw new Exception()s with it