Path: csiph.com!usenet.pasdenom.info!weretis.net!feeder4.news.weretis.net!ecngs!feeder2.ecngs.de!newsfeed.freenet.ag!news2.euro.net!newsgate.cistron.nl!newsgate.news.xs4all.nl!post.news.xs4all.nl!not-for-mail Return-Path: X-Original-To: python-list@python.org Delivered-To: python-list@mail.python.org X-Spam-Status: OK 0.028 X-Spam-Evidence: '*H*': 0.94; '*S*': 0.00; 'imports': 0.09; 'lawrence': 0.09; 'subject:module': 0.09; 'cc:addr:python-list': 0.10; 'subject:run': 0.16; 'wrote:': 0.17; '>>>': 0.18; 'import': 0.21; 'cc:2**0': 0.23; 'absolute': 0.23; 'seems': 0.23; 'cc:no real name:2**0': 0.24; 'cc:addr:python.org': 0.25; 'header:In- Reply-To:1': 0.25; 'header:User-Agent:1': 0.26; 'am,': 0.27; 'relative': 0.30; 'anyone': 0.33; 'but': 0.36; 'subject:with': 0.36; 'too': 0.36; 'does': 0.37; 'well.': 0.37; 'subject:: ': 0.38; 'mark': 0.38; 'think': 0.40; 'received:194': 0.61; 'helps': 0.63; 'everything.': 0.84; 'gelonida': 0.84 X-IronPort-AV: E=Sophos;i="4.80,397,1344204000"; d="scan'208";a="712374" X-Virus-Scanned: amavisd-new at zimbra.sequans.com Date: Mon, 10 Sep 2012 11:28:23 +0200 From: Jean-Michel Pichavant User-Agent: Mozilla-Thunderbird 2.0.0.24 (X11/20100328) MIME-Version: 1.0 To: Gelonida N Subject: Re: how to run python2.6 module with absolute imports stand alone References: In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: python-list@python.org X-BeenThere: python-list@python.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: General discussion list for the Python programming language List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Newsgroups: comp.lang.python Message-ID: Lines: 16 NNTP-Posting-Host: 2001:888:2000:d::a6 X-Trace: 1347269313 news.xs4all.nl 6899 [2001:888:2000:d::a6]:55691 X-Complaints-To: abuse@xs4all.nl Xref: csiph.com comp.lang.python:28809 Gelonida N wrote: > On 09/08/2012 02:13 AM, Mark Lawrence wrote: >> [snip] >>> >> >> I hope this helps >> http://stackoverflow.com/questions/3616952/how-to-properly-use-relative-or-absolute-imports-in-python-modules >> > > It seems the safest bet seems to be to not use relative imports. That's what I figured as well. I may have been misusing relative imports, but I never found the solution for my problems. Absolute imports just solved everything. I think this is the way to go for anyone who does not want to spend too much brain on their import directives. JM