Sick problem with Python properties

Michael Chermside mcherm at mcherm.com
Thu Aug 7 07:45:30 EDT 2003


aj writes:
> See the following code. I wonder why in this case neither
> setp() nor getp() is called !?
      [... code ...]
>     pp = property(getp, setp)
      [... more code ...]
> inst.p = 9
> print inst.p

Because you named it "pp", but then tried using "p" instead.

-- Michael Chermside







More information about the Python-list mailing list