.NET PowerShell notebook does not work with Plotly
See original GitHub issueDescribe the bug
Trying to execute code within a .NET PowerShell notebook (locally using Jupyter lab, locally using VS Code and also online) does throw an error when trying to display Plotly charts via New-PlotlyChart
.
Example code:
`$chart = [Graph.Bar]::new()
$chart.x = 20,14,23 $chart.y = ‘lions’, ‘tigers’, ‘bears’ $chart.orientation=‘h’
New-PlotlyChart -Trace $chart | Out-Display`
Error: InvalidOperation: Unable to find type [Graph.Bar]. The term ‘New-PlotlyChart’ is not recognized as a name of a cmdlet, function, script file
Please complete the following:
Which version of .NET Interactive are you using? There are a few ways to find this out: 1.0.216002+26986fc7149e69110f7485a7e02d5f8db166eebf
- OS
- [x ] Windows 10
- macOS
- Linux (Please specify distro)
- iOS
- Android
- Browser
- [x ] Chrome
- Edge
- Firefox
- Safari
- Frontend
- Jupyter Notebook
- [ x] Jupyter Lab
- nteract
- [ x] Visual Studio Code
- Visual Studio Code Insiders
- Other (please specify)
Screenshots
Issue Analytics
- State:
- Created 2 years ago
- Comments:26 (13 by maintainers)
Top Results From Across the Web
Troubleshooting in Python
How to troubleshoot import and rendering problems in Plotly with Python. ... you are rendering figures: Dash, Jupyter Lab or Classic Notebook, VSCode...
Read more >.NET Interactive: Jupyter Notebooks with .NET Core - Preview 2
NET Interactive is embedding code into a Jupyter Notebook. ... The initial preview is fairly basic but can run PowerShell code and display ......
Read more >XPlot.Plotly.Interactive 4.0.7
Enables XPlot.Plotly to be used in .NET Interactive. When you use this package, you can embed Plotly charts directly into a .NET Interactive...
Read more >Using .NET Core in Jupyter Notebook | Devportal
Open the Windows Command Prompt and use the following commands to install Jupyter Notebook.
Read more >LIVE : .NET Interactive Notebooks with C#/F# in VS Code
Join Diego as he discusses some of the experiences he and his team are building to create improve experiences using notebooks.
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
I would not call then diversions, they are interesting takes and feature improvements! Thank you for the contributions to the project. I would love to see more work that makes extension and api even more tuned into the kernel language consuming it. That will make the user experience incredibly better.
@dfinke
Sorry fingers going faster than brain when I pasted. The whole thing is
The output is
Notice it’s gone back to
--default-kernel csharp
@colombod
Which gives me a clue If I change it to the last one This disappears
The language on the cell is respected and the two command lines become
Every time I exit and restart vs code it reverts to the Jupyter version which would explain why I was getting the old version of .NET Interactive which was associated with the Jupyter Server and couldn’t get
#!about
show anything current.If I start the server in anaconda and go to the browser I get these kernels
Not quite the same set, and I get a third set in Az Data Studio.
Back at plotly It needs to be added manually and downloaded for each session ? Is that expected to remain ?