Skip to content

Commit 25a96af

Browse files
committed
Surface line number for .net exceptions.
1 parent 9e4fb86 commit 25a96af

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

DSPythonNet3/DSPythonNet3Evaluator.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -440,7 +440,7 @@ private static void InitializeEncoders()
440440
/// <returns>Trace back message</returns>
441441
private static string GetTraceBack(Exception e)
442442
{
443-
if (e is not PythonException pythonExc)
443+
if (e is not PythonException pythonExc || pythonExc.Traceback == null)
444444
{
445445
return null;
446446
}

0 commit comments

Comments
 (0)