From 96914baec215857e16abb95be4fee222498f0ee7 Mon Sep 17 00:00:00 2001 From: Tuomas Hietanen Date: Sun, 22 Sep 2024 16:11:13 +0100 Subject: [PATCH] Mac CI debugging (#2827) Debugging of #2814 Adds catching `PlatformNotSupportedException` and `NotSupportedException` on a process starting --- src/app/Fake.Core.Process/Process.fs | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/src/app/Fake.Core.Process/Process.fs b/src/app/Fake.Core.Process/Process.fs index b699dd7c8c6..313b99c79a9 100644 --- a/src/app/Fake.Core.Process/Process.fs +++ b/src/app/Fake.Core.Process/Process.fs @@ -457,6 +457,8 @@ module Process = try proc.StartTime with + | :? PlatformNotSupportedException + | :? NotSupportedException | :? InvalidOperationException | :? System.ComponentModel.Win32Exception as e -> let hasExited = @@ -464,9 +466,10 @@ module Process = proc.HasExited with | :? InvalidOperationException - | :? System.ComponentModel.Win32Exception -> false + | :? NotSupportedException + | :? System.ComponentModel.Win32Exception as e2 -> false - if not hasExited then + if (not hasExited) && (Environment.isWindows || Trace.isVerbose false) then Trace.traceFAKE "Error while retrieving StartTime of started process: %O" e DateTime.Now