Adds detail to message so that user isn't going WTF SDK (#351)
* Adds detail to message so that user isn't going WTF SDK * update exception tests
This commit is contained in:
@@ -171,7 +171,7 @@ public sealed class ObjectLoader(
|
||||
cancellationToken.ThrowIfCancellationRequested();
|
||||
if (Exception is not null)
|
||||
{
|
||||
throw new SpeckleException("Error while loading", Exception);
|
||||
throw new SpeckleException($"Error while loading: {Exception.Message}", Exception);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -97,7 +97,7 @@ public sealed class SerializeProcess(
|
||||
//order here matters...null with cancellation means a user did it, otherwise it's a real Exception
|
||||
if (objectSaver.Exception is not null)
|
||||
{
|
||||
throw new SpeckleException("Error while sending", objectSaver.Exception);
|
||||
throw new SpeckleException($"Error while sending: {objectSaver.Exception.Message}", objectSaver.Exception);
|
||||
}
|
||||
_processSource.Token.ThrowIfCancellationRequested();
|
||||
}
|
||||
|
||||
+1
-1
@@ -6,6 +6,6 @@
|
||||
"Message": "The method or operation is not implemented.",
|
||||
"Type": "NotImplementedException"
|
||||
},
|
||||
"Message": "Error while sending",
|
||||
"Message": "Error while sending: The method or operation is not implemented.",
|
||||
"Type": "SpeckleException"
|
||||
}
|
||||
|
||||
+1
-1
@@ -6,6 +6,6 @@
|
||||
"Message": "Count exceeded",
|
||||
"Type": "Exception"
|
||||
},
|
||||
"Message": "Error while sending",
|
||||
"Message": "Error while sending: Count exceeded",
|
||||
"Type": "SpeckleException"
|
||||
}
|
||||
|
||||
+1
-1
@@ -6,6 +6,6 @@
|
||||
"Message": "The method or operation is not implemented.",
|
||||
"Type": "NotImplementedException"
|
||||
},
|
||||
"Message": "Error while loading",
|
||||
"Message": "Error while loading: The method or operation is not implemented.",
|
||||
"Type": "SpeckleException"
|
||||
}
|
||||
|
||||
+1
-1
@@ -6,6 +6,6 @@
|
||||
"Message": "The method or operation is not implemented.",
|
||||
"Type": "NotImplementedException"
|
||||
},
|
||||
"Message": "Error while sending",
|
||||
"Message": "Error while sending: The method or operation is not implemented.",
|
||||
"Type": "SpeckleException"
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user