Re: Circular imports (again)

2010-08-10 Thread Frank Millman
Frank Millman fr...@chagford.com wrote in message news:i3ov9e$du...@dough.gmane.org... Hi all I know the problems related to circular imports, and I know some of the techniques to get around them. However, I find that I bump my head into them from time to time, which means, I guess, that I

Circular imports (again)

2010-08-09 Thread Frank Millman
Hi all I know the problems related to circular imports, and I know some of the techniques to get around them. However, I find that I bump my head into them from time to time, which means, I guess, that I have not fully understood how to organise my code so that I avoid them in the first

Re: Circular imports (again)

2010-08-09 Thread Ethan Furman
Frank Millman wrote: Hi all I know the problems related to circular imports... It has just happened again. I have organised my code into three modules, each representing a fairly cohesive functional area of the overall application. However, there really are times when Module A wants to

Re: Circular imports (again)

2010-08-09 Thread Carl Banks
On Aug 9, 6:19 am, Frank Millman fr...@chagford.com wrote: It has just happened again. I have organised my code into three modules, each representing a fairly cohesive functional area of the overall application. However, there really are times when Module A wants to invoke something from

Re: Circular imports (again)

2010-08-09 Thread Michael Torrie
On Aug 9, 6:19 am, Frank Millman fr...@chagford.com wrote: It has just happened again. I have organised my code into three modules, each representing a fairly cohesive functional area of the overall application. However, there really are times when Module A wants to invoke something from

Imports again...

2010-04-09 Thread Alex Hall
Hello all, once again: http://www.gateway2somewhere.com/sw/sw.zip The above link is to a project. I am new to using multiple files in Python, and I have a lot of tangled imports where many files in the same folder are importing each other. When I tried to follow the manual to make some files into

Re: Imports again...

2010-04-09 Thread Tim Golden
On 08/04/2010 14:16, Alex Hall wrote: The above link is to a project. I am new to using multiple files in Python, and I have a lot of tangled imports where many files in the same folder are importing each other. When I tried to follow the manual to make some files into packages, it did not work.

Re: Imports again...

2010-04-09 Thread Thomas Guettler
Hi, please post your traceback. I guess you have a recursive import. This can lead to strange exceptions (for example AttributeError) Thomas Alex Hall wrote: Hello all, once again: http://www.gateway2somewhere.com/sw/sw.zip The above link is to a project. I am new to using multiple files

Re: Imports again...

2010-04-09 Thread Gabriel Genellina
On 8 abr, 10:16, Alex Hall mehg...@gmail.com wrote: Hello all, once again:http://www.gateway2somewhere.com/sw/sw.zip The above link is to a project. I am new to using multiple files in Python, and I have a lot of tangled imports where many files in the same folder are importing each other.

Re: Imports again...

2010-04-09 Thread Tim Golden
On 09/04/2010 15:19, Gabriel Genellina wrote: In addition to what Tim Golden has said (which appears to be based on another version of this project Just downloaded again, and there's definitely an empty package structure of the kind I described. (Altho' I certainly did have a few other

Re: Imports again...

2010-04-09 Thread Alex Hall
Okay, what you all say makes sense, and I am going to try the package thing again. The modes dir is from my last attempt, as is its weather subdir. I think I see what I did wrong, at least I hope I do. I will also remove the init file from the main dir. Yes, arm is the main directory of the

Re: Imports again...

2010-04-09 Thread Ethan Furman
Tim Golden wrote: On 09/04/2010 15:19, Gabriel Genellina wrote: In addition to what Tim Golden has said (which appears to be based on another version of this project Just downloaded again, and there's definitely an empty package structure of the kind I described. (Altho' I certainly did have

Re: Imports again...

2010-04-09 Thread Gabriel Genellina
En Fri, 09 Apr 2010 11:29:50 -0300, Tim Golden m...@timgolden.me.uk escribió: On 09/04/2010 15:19, Gabriel Genellina wrote: In addition to what Tim Golden has said (which appears to be based on another version of this project Just downloaded again, and there's definitely an empty package

Re: Imports again...

2010-04-09 Thread Gabriel Genellina
En Fri, 09 Apr 2010 13:10:44 -0300, Alex Hall mehg...@gmail.com escribió: c:\Python26python.exe i:\arm\main.pyw Traceback (most recent call last): File i:\arm\main.pyw, line 3, in module import arm, network, weather, dict File i:\arm\arm.py, line 4, in module import config File

Re: imports again

2010-04-07 Thread Gabriel Genellina
En Tue, 06 Apr 2010 14:25:38 -0300, Alex Hall mehg...@gmail.com escribió: Sorry this is a forward (long story involving a braille notetaker's bad copy/paste and GMail's annoying mobile site). Basically, I am getting errors when I run the project at http://www.gateway2somewhere.com/sw.zip

imports again

2010-04-06 Thread Alex Hall
. -- Forwarded message -- From: Alex Hall mehg...@gmail.com Date: Tue, 6 Apr 2010 13:06:24 -0400 Subject: imports again To: python-us...@python.org Hello all, My project is stalled because of an import problem. I know my imports are a tangled mess (1 imports 2 3 and 4, 2 imports 1 and 3, 3 imports 2