Matthias Bussonnier <bussonniermatth...@gmail.com> added the comment:

> Can you all please decide which issue to use?

We can stay here, I opened the other issue before figuring out this was the 
cause.

> If IPython wants to output the help on the instance, it should change the 
> implementation of `?` and `??`. It would be better if it correctly attribute 
> the source of the docstring: the object itself, its class or its superclass. 
> It was difficult to distinguish these cases before, now it is easier.

Sure I can do that, but this issue feel like a important semantic change of 
`inspect.getdoc()`, it may be documented but there is no warning or deprecation 
of behavior. It is also likely to affect untested code (documentation 
generation).

If you decide that this change of behavior is the one you want I'll be happy to 
support you – I just want to make sure the impact on the rest of the ecosystem. 
IPython/Jupyter is likely not the only one to rely on inspect.getdoc behavior, 
I'm thinking pycharm, spyder, sphinx will likely be impacted. I can see 
`inspect.getdoc()` in the source of even scipy/numpy and rarely in tests.


I would prefer new functions with clearer behavior and for example returning a 
sequence of tuple (docs, where it comes from) potentially deprecating 
inspect.getdocs() than a change of behavior that remove data where their used 
to be some


>  I just tried IPython 5.5.0

(You may want to update to 5.10, and do you have reason to still be on 5 and 
not 7 ?)

----------

_______________________________________
Python tracker <rep...@bugs.python.org>
<https://bugs.python.org/issue40257>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to