Do you have an empty __init__.py
file in both directories to let python know that the dirs are modules?
The basic outline when you are not running from within the folder (ie maybe from pylint's, though I haven't used that) is:
topdir\
__init__.py
functions_etc.py
subdir\
__init__.py
other_functions.py
This is how the python interpreter is aware of the module without reference to the current directory, so if pylint is running from its own absolute path it will be able to access functions_etc.py
as topdir.functions_etc
or topdir.subdir.other_functions
, provided topdir
is on the PYTHONPATH
.
UPDATE: If the problem is not the __init__.py
file, maybe just try copying or moving your module to c:\Python26\Lib\site-packages
-- that is a common place to put additional packages, and will definitely be on your pythonpath. If you know how to do Windows symbolic links or the equivalent (I don't!), you could do that instead. There are many more options here: http://docs.python.org/install/index.html, including the option of appending sys.path with the user-level directory of your development code, but in practice I usually just symbolically link my local development dir to site-packages - copying it over has the same effect.