Git Product home page Git Product logo

Comments (12)

VoVAllen avatar VoVAllen commented on June 3, 2024

It seems you have multiple python installed on your machine. And the extension in vscode extension shop hasn't be updated for a while.

from ffi-navigator.

tqchen avatar tqchen commented on June 3, 2024

It would be great if you can get a repro, see some of the testcases here https://github.com/tqchen/ffi-navigator/blob/master/tests/python/test_langserver.py

through a dummy repo location and desired target. The current version seems work fine on my side

from ffi-navigator.

tqchen avatar tqchen commented on June 3, 2024

cc @comaniac

from ffi-navigator.

comaniac avatar comaniac commented on June 3, 2024

The current version (extension on marketplace and the python package on PyPI) works for me on Linux and OSX.

  1. Sorry for the typo. It has been fixed in upstream but not yet updated on marketplace (@tqchen should we setup a Github action workflow or similar mechanism to upload a new version automatically?)

  2. As @VoVAllen mentioned, please make sure the ffi_navigator package is installed for the python you are using in VSCode. If everything works fine, you should not see the warning like "No definition found ...". Even the language server doesn't work as expected, you should just see an empty definition list shown in VSCode extension log tab instead of a popping up widget.

from ffi-navigator.

tqchen avatar tqchen commented on June 3, 2024

Updated the vscode extension

from ffi-navigator.

tqchen avatar tqchen commented on June 3, 2024

@fleebeatles please update the vscode extension to the lastest 0.6.1 and try again

from ffi-navigator.

fleebeatles avatar fleebeatles commented on June 3, 2024

Thanks all for your reply.
I updated the vscode extension and it still wouldn't work. And I tried the testcase you @tqchen posted and it worked fine. FYI, the configurations of my working enviroment is as follows.

  • The system is macos 10.14.6.
  • Yes @VoVAllen I am using conda to manage the virtual env of Python and I installed ffi_navigator on both base env and tvm env (and even the system's default python env). The dependency packages of TVM are installed in tvm env using "conda" or "pip". However, vscode notifies that "ffi_navigator is not installed..." as before.
  • In vscode, the Python interpreter is directed to the Python path of tvm env.
    image
    Besides, I found that not only the Python and C++ codes couldn't jump to the other part, but the defination of the references to tvm or vta packages couldn't be found either, as shown below. However, the TVM Python code indeed runs properly.
    image

Appreciate it if someone give advice.

from ffi-navigator.

VoVAllen avatar VoVAllen commented on June 3, 2024

Did you choose the right python interpreter at the bottom bar?

from ffi-navigator.

VoVAllen avatar VoVAllen commented on June 3, 2024

And the configuration path for ffi navigator is

{
  "ffi_navigator.pythonpath": "<your-python-path>"
}

from ffi-navigator.

fleebeatles avatar fleebeatles commented on June 3, 2024

I think so @VoVAllen. Please check the followed.
image

from ffi-navigator.

comaniac avatar comaniac commented on June 3, 2024

If your VSCode cannot find tvm, it is nothing to do with ffi_navigator. This is because the PYTHONPATH VSCode is using does not come from your environment. The most promising way I am using is creating a file <your-tvm-path>/.env with the following:

PYTHONPATH=<your-tvm-path>/python:<your-tvm-path>/topi/python

To make this file effective, you have to either open VSCode directly in <your-tvm-path>, or open VSCode first and File->Open-><your-tvm-path>.

from ffi-navigator.

fleebeatles avatar fleebeatles commented on June 3, 2024

@VoVAllen Setting the right path of python interpreter for ffi-navigator works! Thanks a lot.
@comaniac You are right and thank you very much.
And want to say sorry to everyone concerned with this issue, because the README of ffi-navigator has explained how to solve this problem and I didn't read it.

from ffi-navigator.

Related Issues (10)

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.