Consider the following very simple Python project tree:
. ├── main.py └── second.py main.py:
import second as s def foo(arg): arg.helloWorld() foo(s) second.py:
def helloWorld(): print("Hello World!") My Jedi setup in ~/.emacs.d/init.el is the same as this file, but you can also see my exact setup here.
This project runs fine (python main.py outputs Hello World!) but running jedi:goto-definition on the helloWorld in arg.helloWorld() gives Definition not found.. However, if I were to change main.py directly to:
import second as s s.helloWorld() Now jedi:goto-definition works and jumps to the def helloWorld() in second.py! So it looks to be a problem with Jedi not recognizing arg as coming from s? I am new to Python and maybe there is an intricacy that I am missing... but the bottom line is that I want Jedi to jump to the definition of helloWorld. How do I achieve this? Thanks for helping!