Am 11.12.2010 20:29, schrieb nap:
>
>         * Why did you comment out the decorators in properties.py?
>
[...]
> I got problem to make them work (need 2 arguments, only give one) so I
> just comment them out and I'll try to enable them later.
Sorry, this is my fault. A statc methof does not take "self" as first
argument. It is static and not related to any object or class.
>
>         * Why are you still using these functions to_int, to_bool, etc?
>
> Yes it add overhead, but this patch was to make dict objects, without
> changing the way parameters are managed. I prefer change the behaviour
> in another pass.
IC.
>
>     * You introduced 'has_default' since some properties use
>       'default=None'. But None is no valid default value at all. If
>       you look at usage of 'default=None', you'll see all (except of
>       one) being StringProps. And None is not a valid string, this is
>       must not be the default for a StringProp.
>
> Yes, StringProp is used every where we do not need to work on the
> value. I think we will need a real type for "objects" like it (do
> nothing, but maybe in the future we will need to work on string, so
> it's better to have another class).
>
>         * Default parameters for Property.__init__() are wrong:
>               o managed and unmanaged are redundant (I propose
>                 removing unmanaged)
>
> But Unmanaged is a class isn't it?
I meant the "unmanaged" attribute here. Property still hat
>
>               o fill_brok defaults to [] which should be None (and the
>                 list set later)
>
> Why? It's easier to just "apply" the value export for all than check
> if it's none, then if not apply it. It make one set less.
The explanation is a bit lengthy, so please see
<http://effbot.org/zone/default-values.htm>. Hudson moans on it with
reason.
>
>               o UnusedProp.managed = True??
>
> To parse all objects in the managed (and not check if not unused).
But "Unused" is unused. Why it is managed? And the correct check is for
not unused. (Otherwise unused is a redundant test.
>
>     As you remember I suggested rietveld for discussion patches. This
>     is why :-)
>
> Emails are quite good too :)
Yes, but it's easier to refer to concrete lines of code in the patch. I
have been sceptical on this, but changed my mind. Esp. for larger
changes (like this one) this helps finding bugs or errors early.
> Thanks again for the patches and the convert tool! (same me hours of
> work!).
You're welcome. This made my love lib2to3. If you like, I'll prepare
fixer for adding a space to all comments.

-- 
Schönen Gruß - Regards
Hartmut Goebel
Dipl.-Informatiker (univ.), CISSP, CSSLP

Goebel Consult 
Spezialist für IT-Sicherheit in komplexen Umgebungen
http://www.goebel-consult.de

Monatliche Kolumne: http://www.cissp-gefluester.de/
Goebel Consult mit Mitglied bei http://www.7-it.de

Attachment: smime.p7s
Description: S/MIME Cryptographic Signature

------------------------------------------------------------------------------
Oracle to DB2 Conversion Guide: Learn learn about native support for PL/SQL,
new data types, scalar functions, improved concurrency, built-in packages, 
OCI, SQL*Plus, data movement tools, best practices and more.
http://p.sf.net/sfu/oracle-sfdev2dev 
_______________________________________________
Shinken-devel mailing list
Shinken-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/shinken-devel

Reply via email to