[issue41287] __doc__ attribute is not set in property-derived classes

2020-07-12 Thread Sergei Izmailov


New submission from Sergei Izmailov :

MRE: 

class Property(property):
pass

print(Property(None, None, None, "hello").__doc__)

Expected: 
hello

Actual:
None

--
messages: 373571
nosy: Sergei Izmailov
priority: normal
severity: normal
status: open
title: __doc__ attribute is not set in property-derived classes

___
Python tracker 
<https://bugs.python.org/issue41287>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue41287] __doc__ attribute is not set in property-derived classes

2020-07-14 Thread Sergei Izmailov


Sergei Izmailov  added the comment:

class Property(property):
'custom docstring'

print(Property(None, None, None, "hello").__doc__)

This snippet is expected to print "hello" as well (at least it's what comment 
in cpython implementation suggests) 

https://github.com/python/cpython/blob/master/Objects/descrobject.c#L1712-L1715

--

___
Python tracker 
<https://bugs.python.org/issue41287>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue41287] __doc__ attribute is not set in property-derived classes

2020-11-09 Thread Sergei Izmailov


Change by Sergei Izmailov :


--
keywords: +patch
pull_requests: +22103
stage:  -> patch review
pull_request: https://github.com/python/cpython/pull/23205

___
Python tracker 
<https://bugs.python.org/issue41287>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com