This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

classification
Title: fset not working
Type: behavior Stage:
Components: None Versions: Python 2.5
process
Status: closed Resolution: wont fix
Dependencies: Superseder:
Assigned To: Nosy List: _doublep, georg.brandl, ryansturmer
Priority: normal Keywords:

Created on 2008-03-24 18:27 by ryansturmer, last changed 2022-04-11 14:56 by admin. This issue is now closed.

Files
File name Uploaded Description Edit
params.py ryansturmer, 2008-03-24 18:27
Messages (3)
msg64427 - (view) Author: Ryan Sturmer (ryansturmer) Date: 2008-03-24 18:27
Using the attached module, There's an asymmetry between fget and fset in
my properties.  fget works fine, but fset isn't getting called.  I'm
fairly sure I'm creating the property correctly.  Try the following code:

a = EWAssayIntParam('myparam', 4)
a.value
a.value = 10
a.value

I've seen this same issue flare up and die out several times in the
tracker, is this a commonly made programming mistake rather than a bug?
msg64430 - (view) Author: Paul Pogonyshev (_doublep) Date: 2008-03-24 18:58
This is caused by EWAssayParam being an old-style class.  Dunno if it is
a bug in Python or not.
msg64431 - (view) Author: Georg Brandl (georg.brandl) * (Python committer) Date: 2008-03-24 19:04
It's not a bug in Python. Properties, being descriptors, only work fully
with new-style classes.
History
Date User Action Args
2022-04-11 14:56:32adminsetgithub: 46726
2008-03-24 19:04:49georg.brandlsetstatus: open -> closed
resolution: wont fix
messages: + msg64431
nosy: + georg.brandl
2008-03-24 18:58:23_doublepsetnosy: + _doublep
messages: + msg64430
2008-03-24 18:27:12ryansturmercreate