super cannot invoke descriptors #60567
Copy link
Copy link
Closed
Labels
interpreter-core(Objects, Python, Grammar, and Parser dirs)(Objects, Python, Grammar, and Parser dirs)type-featureA feature request or enhancementA feature request or enhancement
Description
| BPO | 16363 |
|---|---|
| Nosy | @bitdancer, @RonnyPfannschmidt |
| Superseder | |
| Files |
Note: these values reflect the state of the issue at the time it was migrated and might not reflect the current state.
Show more details
GitHub fields:
assignee = None
closed_at = <Date 2012-10-30.13:42:37.585>
created_at = <Date 2012-10-30.08:07:59.028>
labels = ['interpreter-core', 'type-feature']
title = 'super cannot invoke descriptors'
updated_at = <Date 2012-10-30.13:42:37.583>
user = 'https://github.com/RonnyPfannschmidt'bugs.python.org fields:
activity = <Date 2012-10-30.13:42:37.583>
actor = 'r.david.murray'
assignee = 'none'
closed = True
closed_date = <Date 2012-10-30.13:42:37.585>
closer = 'r.david.murray'
components = ['Interpreter Core']
creation = <Date 2012-10-30.08:07:59.028>
creator = 'Ronny.Pfannschmidt'
dependencies = []
files = ['27792']
hgrepos = []
issue_num = 16363
keywords = []
message_count = 2.0
messages = ['174184', '174211']
nosy_count = 2.0
nosy_names = ['r.david.murray', 'Ronny.Pfannschmidt']
pr_nums = []
priority = 'normal'
resolution = 'duplicate'
stage = 'resolved'
status = 'closed'
superseder = '14965'
type = 'enhancement'
url = 'https://bugs.python.org/issue16363'
versions = ['Python 2.7', 'Python 3.2', 'Python 3.3', 'Python 3.4']Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
interpreter-core(Objects, Python, Grammar, and Parser dirs)(Objects, Python, Grammar, and Parser dirs)type-featureA feature request or enhancementA feature request or enhancement
Activity
RonnyPfannschmidt commentedon Oct 30, 2012
this means its much harder to have a mixin to change the behaviour of a property
instead of super(Mixin, self).prop = foo
the code is super(Mixin, type(self)).prop.__set__(self, foo)
which is way harder to understand
the attached file demonstrates the problem and has a proof of concept for an extended super allowing descriptor invocations
bitdancer commentedon Oct 30, 2012
I believe this is a duplicate of bpo-14965. If you agree please add yourself to nosy there and review the proposed patch and/or make your own proposal. If you think your issue is different you can reopen this one.