Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

avoid sending proxies from dotnet interactive #2837

Merged
merged 2 commits into from
Mar 15, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 7 additions & 1 deletion NotebookTestScript.dib
Original file line number Diff line number Diff line change
Expand Up @@ -380,9 +380,15 @@ using Microsoft.DotNet.Interactive.Commands;

var _ = Kernel.Root.SendAsync(new SendEditableCode("fsharp","#!share --from csharp x\nx"));

#!markdown

The code below will add 2 markdown cells

#!csharp

using Microsoft.DotNet.Interactive;
using Microsoft.DotNet.Interactive.Commands;

var _ = Kernel.Root.SendAsync(new SendEditableCode("markdown","# markdown cell"));
for(var i = 0; i<2;i++){
var _ = await Kernel.Root.SendAsync(new SendEditableCode("markdown",$"# markdown cell {i}"));
}
5 changes: 4 additions & 1 deletion src/Microsoft.DotNet.Interactive/KernelHost.cs
Original file line number Diff line number Diff line change
Expand Up @@ -129,7 +129,10 @@ public async Task ConnectAsync()

_kernel.VisitSubkernelsAndSelf(k =>
{
kernelInfos.Add(k.KernelInfo);
if (k.KernelInfo.IsProxy == false)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
if (k.KernelInfo.IsProxy == false)
if (!k.KernelInfo.IsProxy)

{
kernelInfos.Add(k.KernelInfo);
}
}, true);

await _defaultSender.SendAsync(
Expand Down