Giter Club home page Giter Club logo

razorinteractive's People

Contributors

dependabot-preview[bot] avatar dependabot[bot] avatar plbonneville avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

Forkers

shupoval

razorinteractive's Issues

Rendering error

Installed Packages: RazorInteractive, 1.0.6

Error: System.ArgumentException: An element with the same key 'test' already exists in the ExpandoObject. (Parameter 'key')
at System.Dynamic.ExpandoObject.TrySetValue(Object indexClass, Int32 index, Object value, String name, Boolean ignoreCase, Boolean add)
at System.Dynamic.ExpandoObject.TryAddMember(String key, Object value)
at System.Dynamic.ExpandoObject.System.Collections.Generic.IDictionary<System.String,System.Object>.Add(String key, Object value)
at RazorInteractive.ModelCreator.<>c.b__1_0(IDictionary2 dictionary, ScriptVariable variable) at System.Linq.ImmutableArrayExtensions.Aggregate[TAccumulate,T](ImmutableArray1 immutableArray, TAccumulate seed, Func3 func) at RazorInteractive.ModelCreator.CreateModelFromCurrentVariables(CSharpKernel csharpKernel) at RazorInteractive.ModelCreator.CreateModelFromCurrentVariables(Kernel kernel) at RazorInteractive.ModelCreator.CreateModelFromCurrentVariables(Kernel kernel) at RazorInteractive.RazorExtensions.<>c__DisplayClass1_01.b__0(RazorMarkdown markdown, TextWriter writer)
at Microsoft.DotNet.Interactive.Formatting.Formatter.<>c__DisplayClass49_01.<Register>b__0(Object value, FormatContext context) in D:\a\_work\1\s\src\Microsoft.DotNet.Interactive.Formatting\Formatter.cs:line 467 at Microsoft.DotNet.Interactive.Formatting.Formatter1.FormatTo(T obj, FormatContext context, String mimeType) in D:\a_work\1\s\src\Microsoft.DotNet.Interactive.Formatting\Formatter{T}.cs:line 65
at Microsoft.DotNet.Interactive.Formatting.Formatter.ToDisplayString(Object obj, String mimeType) in D:\a_work\1\s\src\Microsoft.DotNet.Interactive.Formatting\Formatter.cs:line 264
at Microsoft.DotNet.Interactive.FormattedValue.<>c__DisplayClass7_0.b__1(String mimeType) in D:\a_work\1\s\src\Microsoft.DotNet.Interactive\FormattedValue.cs:line 37
at System.Linq.Enumerable.SelectArrayIterator2.ToArray() at Microsoft.DotNet.Interactive.FormattedValue.FromObject(Object value, String[] mimeTypes) in D:\a\_work\1\s\src\Microsoft.DotNet.Interactive\FormattedValue.cs:line 37 at Microsoft.DotNet.Interactive.KernelInvocationContextExtensions.Display(KernelInvocationContext context, Object value, String[] mimeTypes) in D:\a\_work\1\s\src\Microsoft.DotNet.Interactive\KernelInvocationContextExtensions.cs:line 22 at RazorInteractive.RazorKernel.HandleAsync(SubmitCode command, KernelInvocationContext context) at Microsoft.DotNet.Interactive.Kernel.<>c__DisplayClass72_01.b__0(KernelCommand _, KernelInvocationContext context) in D:\a_work\1\s\src\Microsoft.DotNet.Interactive\Kernel.cs:line 690
at Microsoft.DotNet.Interactive.Kernel.HandleAsync(KernelCommand command, KernelInvocationContext context) in D:\a_work\1\s\src\Microsoft.DotNet.Interactive\Kernel.cs:line 257
at Microsoft.DotNet.Interactive.KernelCommandPipeline.b__6_0(KernelCommand command, KernelInvocationContext context, KernelPipelineContinuation _) in D:\a_work\1\s\src\Microsoft.DotNet.Interactive\KernelCommandPipeline.cs:line 57
at Microsoft.DotNet.Interactive.KernelCommandPipeline.<>c__DisplayClass6_1.<b__3>d.MoveNext() in D:\a_work\1\s\src\Microsoft.DotNet.Interactive\KernelCommandPipeline.cs:line 73
--- End of stack trace from previous location ---
at Microsoft.DotNet.Interactive.CompositeKernel.LoadExtensions(KernelCommand command, KernelInvocationContext context, KernelPipelineContinuation next) in D:\a_work\1\s\src\Microsoft.DotNet.Interactive\CompositeKernel.cs:line 144
at Microsoft.DotNet.Interactive.KernelCommandPipeline.<>c__DisplayClass6_0.<g__Combine|2>d.MoveNext() in D:\a_work\1\s\src\Microsoft.DotNet.Interactive\KernelCommandPipeline.cs:line 74
--- End of stack trace from previous location ---
at Microsoft.DotNet.Interactive.KernelCommandPipeline.SendAsync(KernelCommand command, KernelInvocationContext context) in D:\a_work\1\s\src\Microsoft.DotNet.Interactive\KernelCommandPipeline.cs:line 48

Sharing loaded packages?

I'm trying to use RazorInteractive with Blazor, and I'm having trouble. Starting a cell with
@using Blazor.Diagrams.Components
I'm getting
The type or namespace name 'Blazor' could not be found (are you missing a using directive or an assembly reference?)

My C# cells work fine, though, so I speculate that this is because Razor has some internal C# engine under the hood that hasn't loaded the right assemblies. I have no idea if this is actually true, however, and definitely don't know how I might get that internal engine to load Blazor. Any suggestions?

Add default imports

There should be a list of default imports for namespaces such as:

@using System
@using System.Collections.Generic
@using System.Linq
@using System.Threading.Tasks

Null reference with the variables in the new Razor kernel

Error: System.NullReferenceException: Object reference not set to an instance of an object.
at RazorInteractive.ModelCreator.<>c__DisplayClass1_0.<CreateModelFromCurrentVariables>b__0(String name)
at System.Linq.Enumerable.SelectArrayIterator`2.MoveNext()
at System.Linq.Enumerable.Aggregate[TSource,TAccumulate](IEnumerable`1 source, TAccumulate seed, Func`3 func)
at RazorInteractive.ModelCreator.CreateModelFromCurrentVariables(DotNetKernel dotNetKernel)
at RazorInteractive.ModelCreator.CreateModelFromCurrentVariables(Kernel kernel)
at RazorInteractive.ModelCreator.CreateModelFromCurrentVariables(Kernel kernel)
at RazorInteractive.RazorExtensions.<>c__DisplayClass1_0`1.<UseRazor>b__0(RazorMarkdown markdown, TextWriter writer)

Installing NuGet package fails on VSCode 1.71.2

Invoking the #r "nuget:RazorInteractive" fails consistently:

Error: Microsoft.DotNet.Interactive.KernelExtensionLoadException: Failure loading Kernel Extension
 ---> System.MissingMethodException: Method not found: 'Void Microsoft.DotNet.Interactive.CompositeKernel.Add(Microsoft.DotNet.Interactive.Kernel, System.Collections.Generic.IReadOnlyCollection`1<System.String>)'.
   at RazorInteractive.RazorKernelExtension.OnLoadAsync(Kernel kernel)
   at System.Runtime.CompilerServices.AsyncMethodBuilderCore.Start[TStateMachine](TStateMachine& stateMachine)
   at RazorInteractive.RazorKernelExtension.OnLoadAsync(Kernel kernel)
   at Microsoft.DotNet.Interactive.Extensions.AssemblyBasedExtensionLoader.LoadFromAssembly(FileInfo assemblyFile, Kernel kernel, KernelInvocationContext context) in D:\a\_work\1\s\src\Microsoft.DotNet.Interactive\Extensions\AssemblyBasedExtensionLoader.cs:line 132

image

.NET Interactive Notebooks vscode-extension is v1.0.3452020 (latest presently)

dotnet 6 SDK

❯ winget list dotnet.sdk.6
Name                             Id                     Version Source
-----------------------------------------------------------------------
Microsoft .NET SDK 6.0.401 (x64) Microsoft.DotNet.SDK.6 6.0.401 winget

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.