Author ncoghlan
Recipients Cubky, CuriousLearner, Devin Jeanpierre, eric.araujo, ezio.melotti, jairotrad, jaysinh.shukla, jbitcm-, mikehoy, ncoghlan, r.david.murray, terry.reedy
Date 2017-04-09.09:47:45
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1491731266.76.0.912608987617.issue13691@psf.upfronthosting.co.za>
In-reply-to
Content
After reviewing Sanyam's PR at https://github.com/python/cpython/pull/172 I ended up rejecting it as an approach to resolving this issue.

The core problem with the approach is that accessing `_sitebuiltins._Helper` is an implementation detail twice over:

- Python implementations aren't required to have a _sitebuiltins module
- that module isn't required to contain a _Helper class

That means importing it into a general purpose module like pydoc would couple pydoc specifically to the way CPython works, which is something we try to avoid doing.

By contrast, a richer `__help__()` protocol to override the `__doc__` based default behaviour would allow any object to implement it, and _sitebuiltins._Helper could just use that protocol to special case itself.
History
Date User Action Args
2017-04-09 09:47:46ncoghlansetrecipients: + ncoghlan, terry.reedy, Devin Jeanpierre, ezio.melotti, eric.araujo, r.david.murray, mikehoy, jbitcm-, Cubky, jairotrad, jaysinh.shukla, CuriousLearner
2017-04-09 09:47:46ncoghlansetmessageid: <1491731266.76.0.912608987617.issue13691@psf.upfronthosting.co.za>
2017-04-09 09:47:46ncoghlanlinkissue13691 messages
2017-04-09 09:47:46ncoghlancreate