ANNOUNCE: Thesaurus - a recursive dictionary subclass using attributes

Steven D'Aprano steve+comp.lang.python at pearwood.info
Wed Dec 12 01:34:31 EST 2012


On Tue, 11 Dec 2012 16:08:34 -0500, Dave Cinege wrote:

> On Tuesday 11 December 2012 03:12:19 Steven D'Aprano wrote:
> 
>> Is this intended as a ready-for-production class?
> 
> For me, yes. In production code.
> 
>> py> d = Thesaurus()
>> py> d['spam'] = {}
> 
> Maybe because spam is type dict instead of type thes???

Well duh. By the way, it's a dirty trick to cut out all context to try to 
make me seem like an idiot.

In context, you stated that Thesaurus "will search through nested objects
recursively when __getitem__ is called", but in fact that is not true. It 
does not do what you state it does.


> Remainder of your post, not productive, not worth my time.

Oh well I'm just hurt now. *sobs*

So, let's see now... I identified that your Thesaurus code:

* will fail silently;
* contains dead code that is never used;
* contains redundant code that is pointless;
* hides errors in the caller's code;

and you consider this "not productive, not worth my time". Code review 
with you must be *all* sorts of fun.



-- 
Steven



More information about the Python-list mailing list