I am not able to get code completion for binary python extensions (built with boost python) on Windows platform. I have added them to the project's PYTHONPATH. Do I need to do anything special to get it to work?
Eclipse version: 3.3.2
PyDev Extensions: 1.3.15
You mean the completions that are context-insensitive (those are currently only supported for things available in the static analysis) or any completion from the dll (if you do an import and use it does it work?)
I mean the completions from the DLL that I import in the script. Is this supposed to work?
Yes, it's supposed to work... if you go in the prompt and do "import mydll; print dir(mydll)", does it bring the tokens correctly?
Also, note that it'll get those completions and cache it, if you want to rebuild them you have to do: Ctrl+2 kill<Enter>
It doesn't work. I think these DLLs were not resolved.
I added these DLLs to the External Source Folders list (with the "Add zip/jar/egg" option) in "Pydev - PYTHONPATH" project setting. These DLLs have external native DLL dependencies which I have set in my PATH. Do I need to do anything else?
If you open a command shell (cmd.exe), does it work there? Also, after setting the PATH environment variable, you have to restart eclipse -- and any open shell if you start eclipse from a shell for it to get the new PATH.
yes, it does work from the command line. i launched eclipse.exe from the same command line. I set the "PyDev - PYTHONPATH" to be the same as what I had in the command line environment (external source directories option). I still see the libraries as unresolved import.
Do you have some error in your error log? Also, are you able to get completion on other builtins? (E.g.: in an empty file, requesting a completion brings RuntimeError, AssertionError, etc?)
I think I figured it out. It was a problem with one of the dependent dlls. Thanks a lot for the help.
However, how do I look at the error log in eclipse.
Take a look at: http://pydev.sourceforge.net/faq.html#how_do_i_report_a_bug (it explains how to get the error log info).
Actually, I just realized one thing... you're adding a DLL and not a zip file, so, you should actually add the folder that contains the DLL in your pythonpath, and not the DLL itself...