A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://mail.python.org/pipermail/python-dev/2010-October/104486.html below:

[Python-Dev] question/comment about documentation of relative imports

[Python-Dev] question/comment about documentation of relative imports [Python-Dev] question/comment about documentation of relative importsOleg Broytman phd at phd.pp.ru
Tue Oct 5 23:41:17 CEST 2010
On Wed, Oct 06, 2010 at 07:09:48AM +1000, Nick Coghlan wrote:
> The remaining scenarios we have that can lead to duplication of a
> module happen regardless of the import style you use*.
> 
> Cheers,
> Nick.
> 
> *For the curious - those scenarios relate to ending up with the same
> module present both as "__main__" and under its normal module name.

   I remember falling in the trap of importing the same module twice by
manipulating sys.path and changing cwd (current working directory); the
module was imported from different paths - from the current directory
(entry '.' in the sys.path) and by its full path.

Oleg.
-- 
     Oleg Broytman            http://phd.pp.ru/            phd at phd.pp.ru
           Programmers don't die, they just GOSUB without RETURN.
More information about the Python-Dev mailing list

RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4