Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.python > #20998

Re: Question about circular imports

Path csiph.com!x330-a1.tempe.blueboxinc.net!usenet.pasdenom.info!aioe.org!news.stack.nl!newsfeed.xs4all.nl!newsfeed6.news.xs4all.nl!xs4all!post.news.xs4all.nl!not-for-mail
Return-Path <ethan@stoneleaf.us>
X-Original-To python-list@python.org
Delivered-To python-list@mail.python.org
X-Spam-Status OK 0.002
X-Spam-Evidence '*H*': 1.00; '*S*': 0.00; 'from:addr:ethan': 0.09; 'from:addr:stoneleaf.us': 0.09; 'from:name:ethan furman': 0.09; 'message-id:@stoneleaf.us': 0.09; 'received:184.172': 0.09; 'received:gator410.hostgator.com': 0.09; 'library': 0.13; 'circular': 0.15; 'received:72.11': 0.16; 'received:72.11.125': 0.16; 'received:72.11.125.166': 0.16; 'refactoring': 0.16; 'wrote:': 0.18; 'subject:Question': 0.19; 'trying': 0.21; 'bonus': 0.21; 'header:In-Reply-To:1': 0.22; 'works.': 0.23; 'code': 0.26; 'testing': 0.26; 'separate': 0.28; 'importing': 0.29; 'imported': 0.30; 'header:User-Agent:1': 0.33; '(not': 0.35; 'to:addr:python- list': 0.35; 'but': 0.37; 'think': 0.38; 'easier': 0.38; 'files': 0.39; 'to:addr:python.org': 0.40; 'received:websitewelcome.com': 0.64; 'received:69.93': 0.67
Date Tue, 28 Feb 2012 09:58:28 -0800
From Ethan Furman <ethan@stoneleaf.us>
User-Agent Thunderbird 1.5.0.10 (Windows/20070221)
MIME-Version 1.0
To python-list@python.org
Subject Re: Question about circular imports
References <jid2a9$n21$1@dough.gmane.org> <jid424$vfp$1@dough.gmane.org> <jieaid$e4k$1@dough.gmane.org> <mailman.189.1330323422.3037.python-list@python.org> <XnsA006CA54C1864OKB@88.198.244.100>
In-Reply-To <XnsA006CA54C1864OKB@88.198.244.100>
Content-Type text/plain; charset=ISO-8859-1; format=flowed
Content-Transfer-Encoding 7bit
X-AntiAbuse This header was added to track abuse, please include it with any abuse report
X-AntiAbuse Primary Hostname - gator410.hostgator.com
X-AntiAbuse Original Domain - python.org
X-AntiAbuse Originator/Caller UID/GID - [47 12] / [47 12]
X-AntiAbuse Sender Address Domain - stoneleaf.us
X-BWhitelist no
X-Source
X-Source-Args
X-Source-Dir
X-Source-Sender mail.admailinc.com ([192.168.10.136]) [72.11.125.166]:3310
X-Source-Auth ethan+stoneleaf.us
X-Email-Count 4
X-Source-Cap dG9idWs7dG9idWs7Z2F0b3I0MTAuaG9zdGdhdG9yLmNvbQ==
X-BeenThere python-list@python.org
X-Mailman-Version 2.1.12
Precedence list
List-Id General discussion list for the Python programming language <python-list.python.org>
List-Unsubscribe <http://mail.python.org/mailman/options/python-list>, <mailto:python-list-request@python.org?subject=unsubscribe>
List-Archive <http://mail.python.org/pipermail/python-list>
List-Post <mailto:python-list@python.org>
List-Help <mailto:python-list-request@python.org?subject=help>
List-Subscribe <http://mail.python.org/mailman/listinfo/python-list>, <mailto:python-list-request@python.org?subject=subscribe>
Newsgroups comp.lang.python
Message-ID <mailman.254.1330455105.3037.python-list@python.org> (permalink)
Lines 10
NNTP-Posting-Host 2001:888:2000:d::a6
X-Trace 1330455105 news.xs4all.nl 6972 [2001:888:2000:d::a6]:50486
X-Complaints-To abuse@xs4all.nl
Xref x330-a1.tempe.blueboxinc.net comp.lang.python:20998

Show key headers only | View raw


OKB (not okblacke) wrote:
>     	Anyway, testing this just reinforced my distaste for circular 
> imports.  Just trying to think about how it ought to work with a 
> importing c but then c and d importing each other makes my brain hurt.  
> Refactoring the files so that common code is in a separate library 
> imported by both is easier to understand, and has the nice side bonus 
> that it works.
> 

+1 QOTW

Back to comp.lang.python | Previous | NextPrevious in thread | Find similar | Unroll thread


Thread

Re: Question about circular imports "Frank Millman" <frank@chagford.com> - 2012-02-27 08:16 +0200
  Re: Question about circular imports "OKB (not okblacke)" <brenNOSPAMbarn@NObrenSPAMbarn.net> - 2012-02-28 03:55 +0000
    Re: Question about circular imports Ethan Furman <ethan@stoneleaf.us> - 2012-02-28 09:58 -0800

csiph-web