Skip to content

Commit 0879fd1

Browse files
authored
Bugfix for Microsoft.Spark.Extensions.DotNet.Interactive duplicate file exception (#565)
1 parent 0f576e5 commit 0879fd1

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/csharp/Extensions/Microsoft.Spark.Extensions.DotNet.Interactive/AssemblyKernelExtension.cs

+2-2
Original file line numberDiff line numberDiff line change
@@ -45,6 +45,8 @@ public Task OnLoadAsync(IKernel kernel)
4545

4646
kernelBase.AddMiddleware(async (command, context, next) =>
4747
{
48+
await next(command, context);
49+
4850
if ((context.HandlingKernel is CSharpKernel kernel) &&
4951
(command is SubmitCode) &&
5052
TryGetSparkSession(out SparkSession sparkSession) &&
@@ -57,8 +59,6 @@ public Task OnLoadAsync(IKernel kernel)
5759
sparkSession.SparkContext.AddFile(filePath);
5860
}
5961
}
60-
61-
await next(command, context);
6262
});
6363
}
6464

0 commit comments

Comments
 (0)