Coder Social home page Coder Social logo

Comments (4)

tzachar avatar tzachar commented on June 13, 2024

I don't think TabNine supports this.
As TabNine uses xdg-open with the url, you can circumvent the issue by having your own xdg-open available in your PATH before starting nvim, and logging the arguments sent to it to solve your issue.

from cmp-tabnine.

zhyu avatar zhyu commented on June 13, 2024

Good point about xdg-open, I will give it a try later.

Before switching to nvim-cmp, I have been using coc.nvim. And the extension to coc.nvim for Tabnine is https://github.com/neoclide/coc-tabnine, which configures Tabnine via special commands. It does tell me the URL I should visit to open the Hub:
image

So I think maybe the server responses to the config call with the URL somehow?

from cmp-tabnine.

zhyu avatar zhyu commented on June 13, 2024

So I tried to dump the response from Tabnine after sending the config command to it, and got the following:

{
  message = {
    reason = "Couldn't start web browser at http://127.0.0.1:5555/sec-fxdeccwilpzmniggbpdi. See https://tabnine.com/faq#browser_failed"
  },
  status = "Failure"
}

Accessing the URL above with ssh port forwarding works as expected.

I think it's possible for the plugin to handle the response and display it.

from cmp-tabnine.

zhyu avatar zhyu commented on June 13, 2024

I just found if we send quite = true when opening the hub, TabNine returns the following:

{
  message = "http://127.0.0.1:5555/sec-ssgemthelgmbjhgpscax",
  status = "Success"
}

So one alternative is: having a new command other than CmpTabnineHub (or let user config the behavior) to start the server without calling xdg-open, and then tells user the URL.

Maybe it's better than #59, @tzachar what do you think about it?

from cmp-tabnine.

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.