Can you post the actual code that's failing? Have you checked if those are really in the pythonpath? Have you tried adding them to the forced builtins? See: http://pydev.org/manual_101_interpreter.html for references.
Cheers,
Fabio
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
The "etree" portion of that line is highlighted as an import error.
Based upon your recommendation, I added "lxml" to the Forced Builtins. Assuming simply adding "lxml" to the Forced Builtins would correct things, I can confirm that PyDev still detects the import as an error.
And, yes, it's in the PYTHONPATH. I'm able to import that same line without any errors in a Terminal window running Python.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Anonymous
-
2012-08-12
I had the same issue using PyDev 2.6 for Eclipse. I solved it by building lxml from sources, then building a egg, and then copying the egg into dist-packages folder; but I think it is not necessary to build it from sources, if you get the egg, just add it to dist-packages folder and it should work!
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
I'm using PyDev (1.5.7.2010050621) and I see import errors for the lxml library (http://codespeak.net/lxml/), as well as a couple other libs (PyAMF and pisa). From what I can tell after Googling this problem is that it's happened before (http://www.mail-archive.com/pydev-users@lists.sourceforge.net/msg01135.html).
Am I doing something wrong or is this a new bug? FWIW, this was not happening in earlier versions of PyDev.
Can you post the actual code that's failing? Have you checked if those are really in the pythonpath? Have you tried adding them to the forced builtins? See: http://pydev.org/manual_101_interpreter.html for references.
Cheers,
Fabio
The code is simple:
The "etree" portion of that line is highlighted as an import error.
Based upon your recommendation, I added "lxml" to the Forced Builtins. Assuming simply adding "lxml" to the Forced Builtins would correct things, I can confirm that PyDev still detects the import as an error.
And, yes, it's in the PYTHONPATH. I'm able to import that same line without any errors in a Terminal window running Python.
I had the same issue using PyDev 2.6 for Eclipse. I solved it by building lxml from sources, then building a egg, and then copying the egg into dist-packages folder; but I think it is not necessary to build it from sources, if you get the egg, just add it to dist-packages folder and it should work!