[Python-ideas] Re: Descriptor __get__ and __set__ argument discrepancy

2023-10-18 Thread dn via Python-ideas
On 19/10/2023 18.29, Dom Grigonis wrote: def __get__(self, instance, owner): def __set__(self, instance, value): Is there a reason why `__set__` does not have owner in it’s arguments while `__get__` does? Is this a Python Idea? You may have only given us a couple of lines, when the scope o

[Python-ideas] Re: Descriptor __get__ and __set__ argument discrepancy

2023-10-19 Thread dn via Python-ideas
On 19/10/2023 19.50, Dom Grigonis wrote: Thank you, Good information, thank you. Was not aware of __set_name__. IIRC that was one of the updates/improvements. Thanks to whomsoever...! The: instance.__dict__[self.name] = value may require a bit of thought before it feels comfortable,

[Python-ideas] Re: Descriptor __get__ and __set__ argument discrepancy

2023-10-19 Thread dn via Python-ideas
On 19/10/2023 20.43, Dom Grigonis wrote: On 19 Oct 2023, at 10:27, dn via Python-ideas wrote: On 19/10/2023 19.50, Dom Grigonis wrote: Thank you, Good information, thank you. Was not aware of __set_name__. IIRC that was one of the updates/improvements. Thanks to whomsoever...! The