[Qgis-developer] Debugging QGis Python Plugins with Eclipse+Pydev
santiago at mailinator.com
Wed Feb 24 09:50:42 EST 2010
I've got a problem debugging QGis Python Plugins with Eclipse+Pydev. I wrote
a previous post about that, but with a different software configuration.
First of all, I will describe the new software that I've installed in my XP
1. OSGeo4W. I selected to install only the following packages:
- Desktop: qgis-unstable (because of this selection many other packages are
selected to be installed apart from qgis-unstable)
- Libs: libs selected by qgis-unstable + gdal16-ecw + gdal16-mrsid +
gdal16-python + libtiff-bin + owslib + pdflib + shapelib + qt4-devel
- Commandline_Utilities: gpsbabel + setup + shell
2. Eclipse Classic 3.5.1
3. Pydev 1.5.4
After that, I've configured PyDev in Eclipse (Window > Preferences > Pydev >
Interpreter-Python) with the python interpreter from OSGeo4W
(C\OSGeo4W\bin\python.exe) and the following environment:
b. Forced Builtins:
c. Environment variables:
Once again, I tested the fTools Plugin as en example to debug. Also, in the
properties of the project, in PyDev-PYTHONPATH, I've added fTools and
fTools/tools folders as Source Folders.
The problem now is that every class, method,... related to PyQt4.QtCore are
not recognized. For other libraries, like PyQt4.QtGui, qgis.core,...,
everything is well recognized. One symptom is that, in Eclipse, for the
lines: "from PyQt4.QtCore import *" there is no "Unused in wild import"
warning, while it is present in every similar imports ("from <library>
Nevertheless, everything works fine when I try to debug with the
instructions given in Mauricio de Paulo's blog
More information: if I execute a Python shell (C\OSGeo4W\bin\python.exe)
with the same environment variables defined previously, there is no problem
with PyQt4.QtCore, every class or variables are well recognized.
So, finally, I can debug, but for PyQt4.QtCore I can´t check the code and I
don't have code completion.
May be I forgot some folder in the PATH variable or a Pydev bug?
If somebody can help me, I'd be very grateful. Regards.
View this message in context: http://n2.nabble.com/PyDev-tp4219688p4626247.html
Sent from the qgis-developer mailing list archive at Nabble.com.
More information about the Qgis-developer