diff --git a/.vscode/launch.json b/.vscode/launch.json
index ca380323..38f07daa 100644
--- a/.vscode/launch.json
+++ b/.vscode/launch.json
@@ -45,7 +45,7 @@
"program": "${workspaceFolder}/service-host/bin/Debug/net8.0/service-host.dll",
"args": [
"--service",
- "SignatureIngestor",
+ "MetadataMapDump",
"--reportingserver",
"https://localhost:7023"
],
diff --git a/hasheous-lib/Classes/DataObjects.cs b/hasheous-lib/Classes/DataObjects.cs
index b3afc2c9..2ec62da6 100644
--- a/hasheous-lib/Classes/DataObjects.cs
+++ b/hasheous-lib/Classes/DataObjects.cs
@@ -2523,7 +2523,8 @@ void AddArticleVariants(string value)
}
}
- Logging.Log(Logging.LogType.Information, "Import Game", "Search candidates: " + String.Join(", ", distinctCandidates));
+ // remove blank entries and any entries that are just punctuation or dashes
+ distinctCandidates = distinctCandidates.Where(c => !string.IsNullOrWhiteSpace(c) && c.Any(char.IsLetterOrDigit)).ToList();
return distinctCandidates;
}
diff --git a/hasheous-lib/Classes/Logging.cs b/hasheous-lib/Classes/Logging.cs
index b8bd15a3..1722e342 100644
--- a/hasheous-lib/Classes/Logging.cs
+++ b/hasheous-lib/Classes/Logging.cs
@@ -213,15 +213,22 @@ static public void Log(LogType EventType, string ServerProcess, string Message,
/// If true, performs ETA calculation for the progress item.
static public void SendReport(string progressItemKey, int? count, int? total, string description, bool performETACalculation = false)
{
- if (report != null)
+ try
{
- _ = report.SendAsync(progressItemKey, count, total, description, performETACalculation).ContinueWith(task =>
+ if (report != null)
{
- if (task.IsFaulted)
+ _ = report.SendAsync(progressItemKey, count, total, description, performETACalculation).ContinueWith(task =>
{
- Console.WriteLine($"[Logging.SendReport] Error sending report: {task.Exception?.InnerException?.Message}");
- }
- }, TaskScheduler.Default);
+ if (task.IsFaulted)
+ {
+ // swallow any exceptions from sending the report to avoid impacting the main process
+ }
+ }, TaskScheduler.Default);
+ }
+ }
+ catch
+ {
+ // swallow any exceptions from sending the report to avoid impacting the main process
}
}
diff --git a/hasheous-lib/Classes/ProcessQueue/Tasks/Dumps.cs b/hasheous-lib/Classes/ProcessQueue/Tasks/Dumps.cs
index 820a2e59..6d1e8d5d 100644
--- a/hasheous-lib/Classes/ProcessQueue/Tasks/Dumps.cs
+++ b/hasheous-lib/Classes/ProcessQueue/Tasks/Dumps.cs
@@ -67,6 +67,22 @@ public class Dumps : IQueueTask
}
};
+ private static string SanitizeFileName(string name)
+ {
+ if (string.IsNullOrWhiteSpace(name))
+ {
+ return "Unknown";
+ }
+
+ string sanitized = name.Trim();
+ foreach (char c in Path.GetInvalidFileNameChars())
+ {
+ sanitized = sanitized.Replace(c, '_');
+ }
+
+ return string.IsNullOrWhiteSpace(sanitized) ? "Unknown" : sanitized;
+ }
+
private async Task