218 references to ExceptionHandling
Microsoft.Build (92)
BackEnd\BuildManager\BuildManager.cs (11)
43
using ExceptionHandling = Microsoft.Build.Framework.
ExceptionHandling
;
801
catch (Exception e) when (!
ExceptionHandling
.IsCriticalException(e))
822
catch (Exception cleanupFailure) when (!
ExceptionHandling
.IsCriticalException(cleanupFailure))
1323
catch (Exception e) when (!
ExceptionHandling
.IsCriticalException(e))
1482
ExceptionHandling
.IsCriticalException(exception),
1836
catch (Exception ex) when (!
ExceptionHandling
.IsCriticalException(ex))
1966
if (
ExceptionHandling
.IsCriticalException(ex))
2330
catch (Exception ex) when (!
ExceptionHandling
.IsCriticalException(ex))
2403
return !
ExceptionHandling
.IsCriticalException(e) && !
ExceptionHandling
.NotExpectedException(e) && e is not BuildAbortedException;
3536
catch (Exception ex) when (!
ExceptionHandling
.IsCriticalException(ex))
BackEnd\BuildManager\EnvironmentVariableValidator.cs (1)
48
catch (Exception e) when (
ExceptionHandling
.IsIoRelatedException(e))
BackEnd\BuildManager\MultiThreadedStrictModeScope.cs (5)
96
catch (Exception entryFailure) when (!
ExceptionHandling
.IsCriticalException(entryFailure))
102
catch (Exception restorationFailure) when (!
ExceptionHandling
.IsCriticalException(restorationFailure))
164
catch (Exception e) when (
ExceptionHandling
.IsIoRelatedException(e))
232
catch (Exception e) when (
ExceptionHandling
.IsIoRelatedException(e))
290
catch (Exception e) when (
ExceptionHandling
.IsIoRelatedException(e))
BackEnd\Client\MSBuildClient.cs (3)
264
catch (Exception ex) when (!
ExceptionHandling
.IsCriticalException(ex) && ex is not PathTooLongException)
540
catch (Exception ex) when (!
ExceptionHandling
.IsCriticalException(ex) && ex is not PathTooLongException)
794
catch (Exception ex) when (!
ExceptionHandling
.IsCriticalException(ex))
BackEnd\Components\BuildRequestEngine\BuildRequestEngine.cs (5)
277
if (
ExceptionHandling
.IsCriticalException(e))
296
if (
ExceptionHandling
.IsCriticalException(e))
337
catch (Exception e) when (!
ExceptionHandling
.IsCriticalException(e))
1472
if (
ExceptionHandling
.IsCriticalException(e))
1511
catch (Exception e) when (!
ExceptionHandling
.IsCriticalException(e))
BackEnd\Components\Communications\NodeProviderOutOfProcBase.cs (4)
308
catch (Exception ex) when (!
ExceptionHandling
.IsCriticalException(ex))
394
catch (Exception ex) when (!
ExceptionHandling
.IsCriticalException(ex))
912
catch (Exception e) when (!
ExceptionHandling
.IsCriticalException(e))
1590
catch (Exception e) when (!
ExceptionHandling
.IsCriticalException(e))
BackEnd\Components\Communications\NodeProviderOutOfProcTaskHost.cs (1)
1010
catch (Exception ex) when (!
ExceptionHandling
.IsCriticalException(ex))
BackEnd\Components\Logging\EventSourceSink.cs (3)
321
if (
ExceptionHandling
.IsCriticalException(exception))
413
if (
ExceptionHandling
.IsCriticalException(exception))
435
if (
ExceptionHandling
.IsCriticalException(exception))
BackEnd\Components\Logging\LoggingService.cs (2)
1580
catch (Exception e) when (!
ExceptionHandling
.IsCriticalException(e) && e is not LoggerException)
1920
catch (Exception e) when (!
ExceptionHandling
.IsCriticalException(e) && e is not LoggerException)
BackEnd\Components\ProjectCache\ProjectCacheService.cs (2)
28
using ExceptionHandling = Microsoft.Build.Framework.
ExceptionHandling
;
1035
if (
ExceptionHandling
.IsCriticalException(e))
BackEnd\Components\RequestBuilder\RequestBuilder.cs (2)
852
if (
ExceptionHandling
.IsCriticalException(ex))
904
catch (Exception ex) when (!
ExceptionHandling
.IsCriticalException(ex))
BackEnd\Components\RequestBuilder\TargetUpToDateChecker.cs (3)
987
catch (Exception e) when (
ExceptionHandling
.IsIoRelatedException(e))
1012
catch (Exception e) when (
ExceptionHandling
.IsIoRelatedException(e))
1047
catch (Exception e) when (
ExceptionHandling
.IsIoRelatedException(e))
BackEnd\Components\RequestBuilder\TaskBuilder.cs (3)
492
catch (Exception e) when (!
ExceptionHandling
.IsCriticalException(e))
876
if (
ExceptionHandling
.IsCriticalException(ex) || Environment.GetEnvironmentVariable("MSBUILDDONOTCATCHTASKEXCEPTIONS") == "1")
967
if (
ExceptionHandling
.IsCriticalException(taskException) || (Environment.GetEnvironmentVariable("MSBUILDDONOTCATCHTASKEXCEPTIONS") == "1"))
BackEnd\Components\Scheduler\Scheduler.cs (4)
2716
catch (Exception e) when (!
ExceptionHandling
.IsCriticalException(e))
2885
catch (Exception e) when (!
ExceptionHandling
.IsCriticalException(e))
2925
catch (Exception e) when (!
ExceptionHandling
.IsCriticalException(e))
2952
catch (Exception e) when (!
ExceptionHandling
.IsCriticalException(e))
BackEnd\Node\InProcNode.cs (1)
324
catch (Exception ex) when (!
ExceptionHandling
.IsCriticalException(ex))
BackEnd\Node\OutOfProcNode.cs (1)
839
catch (Exception ex) when (!
ExceptionHandling
.IsCriticalException(ex))
BackEnd\Node\ServerNamedMutex.cs (1)
47
catch (Exception ex) when (!
ExceptionHandling
.IsCriticalException(ex) && ex is not PathTooLongException)
BackEnd\TaskExecutionHost\TaskExecutionHost.cs (6)
589
catch (Exception e) when (!
ExceptionHandling
.NotExpectedReflectionException(e))
731
catch (Exception e) when (!
ExceptionHandling
.NotExpectedReflectionException(e))
878
catch (Exception e) when (!
ExceptionHandling
.IsCriticalException(e))
1361
catch (Exception e) when (!
ExceptionHandling
.IsCriticalException(e))
1881
catch (Exception e) when (e is not LoggerException && e is not InternalLoggerException && !
ExceptionHandling
.NotExpectedReflectionException(e))
2175
catch (Exception e) when (!
ExceptionHandling
.NotExpectedReflectionException(e))
Construction\ProjectRootElement.cs (2)
2067
catch (Exception ex) when (
ExceptionHandling
.IsIoRelatedException(ex))
2118
catch (Exception ex) when (!
ExceptionHandling
.NotExpectedIoOrXmlException(ex))
Construction\Solution\SolutionFile.cs (1)
748
catch (Exception e) when (
ExceptionHandling
.IsIoRelatedException(e))
Construction\Solution\SolutionProjectGenerator.cs (1)
2255
catch (Exception e) when (!
ExceptionHandling
.IsCriticalException(e)) // We don't want any problems scanning the project file to result in aborting the build.
Definition\Project.cs (1)
468
catch (Exception ex) when (!
ExceptionHandling
.IsCriticalException(ex))
Definition\Toolset.cs (4)
607
catch (Exception e) when (
ExceptionHandling
.IsIoRelatedException(e))
864
catch (Exception e) when (
ExceptionHandling
.IsIoRelatedException(e))
911
catch (Exception e) when (
ExceptionHandling
.IsIoRelatedException(e))
957
catch (Exception e) when (
ExceptionHandling
.IsIoRelatedException(e))
Definition\ToolsetReader.cs (1)
638
catch (Exception e) when (
ExceptionHandling
.IsIoRelatedException(e))
Evaluation\Conditionals\FunctionCallExpressionNode.cs (1)
61
catch (Exception e) when (
ExceptionHandling
.IsIoRelatedException(e))
Evaluation\Evaluator.cs (2)
2226
catch (Exception ex) when (
ExceptionHandling
.IsIoRelatedException(ex))
2271
catch (Exception ex) when (
ExceptionHandling
.IsIoRelatedException(ex))
Evaluation\Expander.Function.cs (1)
602
catch (Exception ex) when (!
ExceptionHandling
.NotExpectedFunctionException(ex))
Evaluation\Expander.ItemExpander.Transforms.cs (4)
129
catch (Exception e) when (!
ExceptionHandling
.NotExpectedException(e) || e is InvalidOperationException)
189
catch (Exception e) when (
ExceptionHandling
.IsIoRelatedException(e))
285
catch (Exception e) when (
ExceptionHandling
.IsIoRelatedException(e))
366
catch (Exception e) when (
ExceptionHandling
.IsIoRelatedException(e))
Evaluation\Expander.PropertyExpander.cs (1)
749
catch (Exception ex) when (!
ExceptionHandling
.NotExpectedRegistryException(ex))
Evaluation\ToolsetElement.cs (1)
102
catch (Exception ex) when (
ExceptionHandling
.IsIoRelatedException(ex))
Instance\TaskFactories\AssemblyTaskFactory.cs (2)
295
catch (Exception e) when (!
ExceptionHandling
.NotExpectedReflectionException(e))
502
catch (Exception e) when (!
ExceptionHandling
.NotExpectedReflectionException(e))
Instance\TaskRegistry.cs (3)
1354
catch (Exception e) when (!
ExceptionHandling
.IsCriticalException(e))
1486
catch (Exception e) when (!
ExceptionHandling
.NotExpectedReflectionException(e))
1580
catch (Exception e) when (!
ExceptionHandling
.IsCriticalException(e))
Logging\BinaryLogger\ProjectImportsCollector.cs (1)
146
catch (Exception e) when (
ExceptionHandling
.IsIoRelatedException(e))
Logging\FileLogger.cs (2)
120
catch (Exception e) when (
ExceptionHandling
.IsIoRelatedException(e))
149
catch (Exception ex) when (
ExceptionHandling
.IsIoRelatedException(ex))
Logging\LoggerDescription.cs (1)
172
when (!(e is LoggerException /* Polite logger Failure*/ || e is InternalLoggerException /* LoggerClass not found*/ ||
ExceptionHandling
.IsCriticalException(e)))
parent\Shared\NodeEndpointOutOfProcBase.cs (1)
530
catch (Exception e) when (!
ExceptionHandling
.IsCriticalException(e))
parent\Shared\RegisteredTaskObjectCacheBase.cs (1)
150
catch (Exception ex) when (!
ExceptionHandling
.IsCriticalException(ex))
parent\Shared\TypeLoader.cs (1)
328
catch (Exception e) when (!
ExceptionHandling
.IsCriticalException(e))
src\msbuild\src\Shared\Debugging\DebugUtils.cs (2)
111
isCritical:
ExceptionHandling
.IsCriticalException(ex));
124
lock (typeof(
ExceptionHandling
))
Microsoft.Build.Framework (18)
FileUtilities_TempFiles.cs (1)
204
catch (Exception ex) when (
ExceptionHandling
.IsIoRelatedException(ex))
FileUtilities.cs (7)
919
catch (Exception ex) when (
ExceptionHandling
.IsIoRelatedException(ex))
1002
catch (Exception ex) when (
ExceptionHandling
.IsIoRelatedException(ex))
1082
catch (Exception ex) when (
ExceptionHandling
.IsIoRelatedException(ex))
1105
catch (Exception e) when (
ExceptionHandling
.IsIoRelatedException(e))
1143
catch (Exception ex) when (
ExceptionHandling
.IsIoRelatedException(ex))
1211
catch (Exception e) when (
ExceptionHandling
.IsIoRelatedException(e))
1468
catch (Exception ex) when (
ExceptionHandling
.IsIoRelatedException(ex))
ItemSpecModifiers.cs (1)
490
catch (Exception e) when (
ExceptionHandling
.IsIoRelatedException(e))
Loader\LoadedType.cs (4)
196
catch (Exception e) when (!
ExceptionHandling
.IsCriticalException(e))
210
catch (Exception e) when (!
ExceptionHandling
.IsCriticalException(e))
229
catch (Exception e) when (!
ExceptionHandling
.IsCriticalException(e))
257
catch (Exception e) when (!
ExceptionHandling
.IsCriticalException(e))
ReflectableTaskPropertyInfo.cs (1)
97
catch (Exception e) when (!
ExceptionHandling
.IsCriticalException(e))
Telemetry\TelemetryManager.cs (1)
108
catch (Exception ex) when (!
ExceptionHandling
.IsCriticalException(ex))
Utilities\FileMatcher.cs (2)
4006
ExceptionHandling
.IsIoRelatedException(exception)
4008
&& aggregateException.Flatten().InnerExceptions.All(
ExceptionHandling
.IsIoRelatedException));
Utilities\FrameworkLocationHelper.cs (1)
1046
catch (Exception e) when (
ExceptionHandling
.IsIoRelatedException(e))
Microsoft.Build.Tasks.Core (74)
AppConfig\AppConfig.cs (1)
54
catch (Exception e) when (
ExceptionHandling
.IsIoRelatedException(e))
AppConfig\BindingRedirect.cs (2)
64
catch (Exception e) when (!
ExceptionHandling
.IsCriticalException(e))
78
catch (Exception e) when (!
ExceptionHandling
.IsCriticalException(e))
AssemblyDependency\AssemblyFoldersFromConfig\AssemblyFoldersFromConfigResolver.cs (1)
141
catch (Exception e) when (e is XmlException ||
ExceptionHandling
.IsIoRelatedException(e))
AssemblyDependency\ReferenceTable.cs (5)
714
catch (Exception e) when (
ExceptionHandling
.IsIoRelatedException(e))
936
catch (Exception e) when (
ExceptionHandling
.IsIoRelatedException(e))
1029
catch (Exception e) when (
ExceptionHandling
.IsIoRelatedException(e))
1263
catch (Exception e) when (
ExceptionHandling
.IsIoRelatedException(e))
3002
catch (Exception e) when (!
ExceptionHandling
.IsCriticalException(e))
AssemblyDependency\ResolveAssemblyReference.cs (2)
1700
catch (Exception e) when (
ExceptionHandling
.IsIoRelatedException(e))
3268
catch (Exception e) when (!
ExceptionHandling
.IsCriticalException(e)
AssemblyDependency\Resolver.cs (1)
339
catch (Exception e) when (
ExceptionHandling
.IsIoRelatedException(e))
Copy.cs (2)
991
catch (Exception e) when (
ExceptionHandling
.IsIoRelatedException(e))
1021
catch (Exception e) when (
ExceptionHandling
.IsIoRelatedException(e))
CreateManifestResourceName.cs (1)
259
catch (Exception e) when (
ExceptionHandling
.IsIoRelatedException(e))
Delete.cs (1)
153
catch (Exception e) when (
ExceptionHandling
.IsIoRelatedException(e))
ErrorFromResources.cs (1)
75
catch (Exception e) when (!
ExceptionHandling
.IsCriticalException(e))
FileIO\ReadLinesFromFile.cs (1)
71
catch (Exception e) when (
ExceptionHandling
.IsIoRelatedException(e))
FileIO\WriteLinesToFile.cs (4)
157
catch (Exception e) when (
ExceptionHandling
.IsIoRelatedException(e))
206
catch (Exception ex) when (attempt < maxAttempts &&
ExceptionHandling
.IsIoRelatedException(ex))
213
catch (Exception e) when (
ExceptionHandling
.IsIoRelatedException(e))
255
catch (Exception e) when (
ExceptionHandling
.IsIoRelatedException(e))
FileState.cs (1)
216
if (!
ExceptionHandling
.IsIoRelatedException(_exceptionThrown))
GenerateResource.cs (7)
1621
catch (Exception e) when (!
ExceptionHandling
.NotExpectedIoOrXmlException(e) || e is MSBuildResXException)
1715
catch (Exception e) when (
ExceptionHandling
.IsIoRelatedException(e))
2721
catch (Exception e) when (
ExceptionHandling
.IsIoRelatedException(e))
2806
catch (Exception e) when (
ExceptionHandling
.IsIoRelatedException(e))
2852
catch (Exception e) when (!
ExceptionHandling
.IsCriticalException(e))
2874
catch (Exception e) when (
ExceptionHandling
.IsIoRelatedException(e))
2965
if (
ExceptionHandling
.NotExpectedException(deleteException))
GetAssemblyIdentity.cs (1)
85
catch (Exception e) when (
ExceptionHandling
.IsIoRelatedException(e))
GetInstalledSDKLocations.cs (1)
160
catch (Exception e) when (!
ExceptionHandling
.IsCriticalException(e))
GetReferenceAssemblyPaths.cs (1)
240
if (
ExceptionHandling
.IsCriticalException(e))
GetSDKReferenceFiles.cs (6)
290
catch (Exception e) when (!
ExceptionHandling
.IsCriticalException(e))
940
catch (Exception e) when (!
ExceptionHandling
.IsCriticalException(e))
970
catch (Exception e) when (!
ExceptionHandling
.IsCriticalException(e))
983
catch (Exception e) when (!
ExceptionHandling
.IsCriticalException(e))
1105
catch (Exception ex) when (!
ExceptionHandling
.IsCriticalException(ex))
1139
catch (Exception e) when (!
ExceptionHandling
.IsCriticalException(e))
ListOperators\FindUnderPath.cs (2)
83
catch (Exception e) when (
ExceptionHandling
.IsIoRelatedException(e))
114
catch (Exception e) when (
ExceptionHandling
.IsIoRelatedException(e))
MakeDir.cs (1)
85
catch (Exception e) when (
ExceptionHandling
.IsIoRelatedException(e))
ManifestUtil\LauncherBuilder.cs (1)
112
catch (Exception ex) when (
ExceptionHandling
.IsIoRelatedException(ex))
Move.cs (1)
174
catch (Exception e) when (
ExceptionHandling
.IsIoRelatedException(e))
parent\Shared\NodePipeServer.cs (1)
151
catch (Exception e) when (!
ExceptionHandling
.IsCriticalException(e))
RedistList.cs (1)
745
catch (Exception ex) when (
ExceptionHandling
.IsIoRelatedException(ex))
RemoveDir.cs (2)
139
catch (Exception e) when (
ExceptionHandling
.IsIoRelatedException(e))
177
catch (Exception e) when (
ExceptionHandling
.IsIoRelatedException(e))
src\msbuild\src\Shared\Debugging\DebugUtils.cs (2)
111
isCritical:
ExceptionHandling
.IsCriticalException(ex));
124
lock (typeof(
ExceptionHandling
))
StateFileBase.cs (3)
81
catch (Exception e) when (!
ExceptionHandling
.NotExpectedSerializationException(e))
152
catch (Exception e) when (!
ExceptionHandling
.IsCriticalException(e))
182
catch (Exception e) when (
ExceptionHandling
.IsIoRelatedException(e))
Touch.cs (4)
191
catch (Exception e) when (
ExceptionHandling
.IsIoRelatedException(e))
263
catch (Exception e) when (
ExceptionHandling
.IsIoRelatedException(e))
279
catch (Exception e) when (
ExceptionHandling
.IsIoRelatedException(e))
295
catch (Exception e) when (
ExceptionHandling
.IsIoRelatedException(e))
WriteCodeFragment.cs (3)
135
catch (Exception ex) when (
ExceptionHandling
.IsIoRelatedException(ex))
576
catch (Exception ex) when (!
ExceptionHandling
.IsCriticalException(ex))
604
catch (Exception ex) when (!
ExceptionHandling
.IsCriticalException(ex))
XmlPeek.cs (4)
77
catch (Exception e) when (!
ExceptionHandling
.IsCriticalException(e))
92
catch (Exception e) when (!
ExceptionHandling
.IsCriticalException(e))
117
catch (Exception e) when (!
ExceptionHandling
.IsCriticalException(e))
130
catch (Exception e) when (!
ExceptionHandling
.IsCriticalException(e))
XmlPoke.cs (4)
87
catch (Exception e) when (!
ExceptionHandling
.IsCriticalException(e))
109
catch (Exception e) when (!
ExceptionHandling
.IsCriticalException(e))
123
catch (Exception e) when (!
ExceptionHandling
.IsCriticalException(e))
150
catch (Exception e) when (!
ExceptionHandling
.IsCriticalException(e))
XmlTaskUtility.cs (1)
54
catch (Exception ex) when (!
ExceptionHandling
.IsCriticalException(ex))
XslTransformation.cs (5)
139
catch (Exception e) when (!
ExceptionHandling
.IsCriticalException(e))
166
catch (Exception e) when (!
ExceptionHandling
.IsCriticalException(e))
184
catch (Exception e) when (!
ExceptionHandling
.IsCriticalException(e))
220
catch (Exception e) when (!
ExceptionHandling
.IsCriticalException(e))
241
catch (Exception ex) when (!
ExceptionHandling
.IsCriticalException(ex))
Microsoft.Build.Utilities.Core (12)
PlatformManifest.cs (1)
157
catch (Exception e) when (!
ExceptionHandling
.IsCriticalException(e))
SDKManifest.cs (1)
358
catch (Exception e) when (!
ExceptionHandling
.IsCriticalException(e))
src\msbuild\src\Shared\Debugging\DebugUtils.cs (2)
111
isCritical:
ExceptionHandling
.IsCriticalException(ex));
124
lock (typeof(
ExceptionHandling
))
ToolLocationHelper.cs (7)
866
catch (Exception e) when (
ExceptionHandling
.IsIoRelatedException(e))
1063
catch (Exception e) when (
ExceptionHandling
.IsIoRelatedException(e))
1183
catch (Exception e) when (
ExceptionHandling
.IsIoRelatedException(e))
1472
catch (Exception e) when (!
ExceptionHandling
.IsCriticalException(e))
3079
catch (Exception e) when (
ExceptionHandling
.IsIoRelatedException(e))
3174
catch (Exception ex) when (
ExceptionHandling
.IsIoRelatedException(ex))
3222
catch (Exception e) when (!
ExceptionHandling
.IsCriticalException(e))
ToolTask.cs (1)
911
catch (Exception e) when (
ExceptionHandling
.IsIoRelatedException(e))
MSBuild (22)
FilteredBinlogReplay.cs (5)
90
catch (Exception ex) when (
ExceptionHandling
.IsIoRelatedException(ex))
225
catch (Exception ex) when (!
ExceptionHandling
.IsCriticalException(ex))
240
catch (Exception ex) when (!
ExceptionHandling
.IsCriticalException(ex))
268
catch (Exception ex) when (!
ExceptionHandling
.IsCriticalException(ex))
283
catch (Exception ex) when (
ExceptionHandling
.IsIoRelatedException(ex))
OutOfProcTaskAppDomainWrapperBase.cs (5)
134
catch (Exception e) when (!
ExceptionHandling
.IsCriticalException(e))
364
catch (Exception e) when (!
ExceptionHandling
.IsCriticalException(e))
404
catch (Exception e) when (!
ExceptionHandling
.IsCriticalException(e))
427
catch (Exception e) when (!
ExceptionHandling
.IsCriticalException(e))
463
catch (Exception e) when (!
ExceptionHandling
.IsCriticalException(e))
OutOfProcTaskHostNode.cs (2)
1482
catch (Exception ex) when (!
ExceptionHandling
.IsCriticalException(ex))
1758
catch (Exception e) when (!
ExceptionHandling
.IsCriticalException(e))
parent\Shared\NodeEndpointOutOfProcBase.cs (1)
530
catch (Exception e) when (!
ExceptionHandling
.IsCriticalException(e))
parent\Shared\RegisteredTaskObjectCacheBase.cs (1)
150
catch (Exception ex) when (!
ExceptionHandling
.IsCriticalException(ex))
parent\Shared\TypeLoader.cs (1)
328
catch (Exception e) when (!
ExceptionHandling
.IsCriticalException(e))
src\msbuild\src\Shared\Debugging\DebugUtils.cs (2)
111
isCritical:
ExceptionHandling
.IsCriticalException(ex));
124
lock (typeof(
ExceptionHandling
))
XMake.cs (5)
250
isCritical:
ExceptionHandling
.IsCriticalException(ex));
1398
ExceptionHandling
.IsCriticalException(exception),
3276
catch (Exception ex) when (
ExceptionHandling
.IsIoRelatedException(ex))
3295
catch (Exception ex) when (
ExceptionHandling
.IsIoRelatedException(ex))
4244
catch (Exception e) when (
ExceptionHandling
.IsIoRelatedException(e))