Giter Site home page Giter Site logo

Comments (7)

Igorgro avatar Igorgro commented on June 16, 2024 1

I have no problems doing this. After installing using instruction in README, the kernel just appeared in the vscode kernel selecton list
image

The only problem is that despite the gopls LSP is starting, there still no autocomplete , but the kernel iteslf working well

from gophernotes.

joelschutz avatar joelschutz commented on June 16, 2024 1

Following up on my previous comment:

  1. The hack is the only way to work with notebooks on most of the languages servers currently. And both VSCode and Jupyter use it in Python.
  2. LSP added support for notebook at version 3.17(latest). This mean that it could be possible to remove the hack.
  3. Both gopls and vscode-go are mantained by Google, and notebook support is not a priority.

Maybe it would be possible to use this to create a middleware to handle notebooks.

from gophernotes.

cosmos72 avatar cosmos72 commented on June 16, 2024

It says "A Visual Studio Code extension that provides basic notebook support for language kernels that are supported in Jupyter Notebooks today" so yes, in theory it may work.

I think nobody tried gophernotes with it yet, so you're welcome to post here the results of any attempt you may want to do.

from gophernotes.

Ale0x78 avatar Ale0x78 commented on June 16, 2024

I keep getting

The 'go' kernel is not available. Please pick another suitable kernel instead, or install that kernel. 

When inside VS-Code (no issues in JupyterLab though). Any chance anyone else has run into this issue?
I tried adding it into trusted kernal's with

"jupyter.kernels.trusted": ["~/Library/Jupyter/kernels/gophernotes"]

But still no luck.

from gophernotes.

Ale0x78 avatar Ale0x78 commented on June 16, 2024

NVM looks like running a JupyterLab server via the terminal and then connecting to it works. Probably some kind of a config thing I am missing in VSCode.

from gophernotes.

Nigel2392 avatar Nigel2392 commented on June 16, 2024

To add to @Igorgro, for me it is working great. Except:

  1. There is no syntax highlighting.
  2. The VSCode Go to Definition functionality does not work (Among others functionality.)

from gophernotes.

joelschutz avatar joelschutz commented on June 16, 2024

I'd been the entire day trying to find a way to do it. It's not a Kernel issue, go-kernel has the same issue.

The main problem is in the VSCode LSP protocol itself, it sends a path to the server to analyze. On the vscode-python they created a hack in the extension to concat a file before sending it the language server.
Captura de tela de 2023-02-09 21-32-08

I don't think it's worth it to create something like it for Go, that's why in trying jupyter now.

from gophernotes.

Related Issues (20)

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.