[ python-Bugs-1207379 ] class property fset not working

SourceForge.net noreply at sourceforge.net
Tue May 24 14:27:48 CEST 2005


Bugs item #1207379, was opened at 2005-05-24 00:02
Message generated for change (Comment added) made by master_jaf
You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=105470&aid=1207379&group_id=5470

Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Category: None
Group: None
Status: Open
Resolution: None
Priority: 5
Submitted By: Master_Jaf (master_jaf)
Assigned to: Nobody/Anonymous (nobody)
Summary: class property fset not working

Initial Comment:
Classes which are not instantiated from 'object',
containing properties, are not working as expected. The
GET method is working but not the SET method. Tested
with python 2.4.1 und 2.3.5.
See sample code file.

----------------------------------------------------------------------

>Comment By: Master_Jaf (master_jaf)
Date: 2005-05-24 14:27

Message:
Logged In: YES 
user_id=1140154

After reading some more documentation I've found at Python
Tutorial "D. Glossary" more hints.
<cite>
Any class that inherits from object. This includes all
built-in types like list and dict. Only new-style classes
can use Python's newer, versatile features like __slots__,
descriptors, properties, __getattribute__(), class methods,
and static methods.
</cite>
Fine. OK, understood..
I'm tending to agree with mwh's opinion, that this is a
documentation bug, although I don't fully understand why the
GET descriptor is working but unlikly not the SET descriptor.

----------------------------------------------------------------------

Comment By: Michael Hudson (mwh)
Date: 2005-05-24 09:58

Message:
Logged In: YES 
user_id=6656

At the very limit, this is a documentation bug.  Why did you think 
properties could be attached to old-style classes?

----------------------------------------------------------------------

You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=105470&aid=1207379&group_id=5470


More information about the Python-bugs-list mailing list