question about module resolution

Peter Otten __peter__ at
Wed Jan 17 17:20:17 CET 2007

Emin wrote:

> I often find myself wanting to have a child module get some parameters
> defined in a parent module. For example, imagine  I have the following
> directory structure and want something in to look at a value in
> I end up putting in things like import sys;
> sys.path.append('../..'). Is there a better way?
> foo/
>      bar/

from __future__ import absolute_import
from .. import config


More information about the Python-list mailing list