pythonpycparserliclipse

"Unresolved import: module" when importing a module into LiClipse


I have installed liclipse 2.4 (Python 3.0 grammar) recently and downloaded pycparser-master.zip file, extracted it, and added the pycparser-master/pycparser/ directory under Project->Properties->PyDev-PYTHONPATH->External Libraries.

I used the below import statement in my Python file.

import pycparser

But the interpreter seems to be throwing an error.

Unresolved import: pycparser

Solution

  • The problem is that you should put "pycparser-master" as the folder in the external libraries (and not pycparser-master/pycparser).