properly implementing the __getattribute__()

John J. Lee jjl at pobox.com
Wed Oct 8 12:18:06 EDT 2003


"Carlo v. Dango" <oest at soetu.eu> writes:

> On Tue, 07 Oct 2003 09:34:27 +0200, Peter Otten <__peter__ at web.de> wrote:
> 
> Many thanks for your quick reply!
> 
> With disbelief i watched how your code worked and mine didn't! Then I
> tried running my code with the -tt flag, which revealed a problem with
> a mix of spaces and tabs :-( Solving that made my code work as well!
> Sigh... this sort of problem is something one really has to get used
> to!
[...]

Only once.  Set up your editor(s) properly, and put a check in your
version control system if you have one, or maybe in your test suite,
if it's not too slow (you can use tabnanny from the standard Python
distribution -- it's both a script and a module, IIRC).


John




More information about the Python-list mailing list