[issue20710] Make pydoc consistent about bound methods

2014-03-17 Thread Roundup Robot
Roundup Robot added the comment: New changeset b2ee3fe195e2 by Larry Hastings in branch '3.4': Issue #20710: The pydoc summary line no longer displays the self parameter http://hg.python.org/cpython/rev/b2ee3fe195e2 -- ___ Python tracker

[issue20710] Make pydoc consistent about bound methods

2014-02-20 Thread Larry Hastings
Larry Hastings added the comment: Okay, that's a fair point. I checked, and the documentation specifically says that ismethod only returns true on bound methods implemented in Python. I think that's a bad API, it should be agnostic about the implementation language. But I'll remove the

[issue20710] Make pydoc consistent about bound methods

2014-02-20 Thread Yury Selivanov
Yury Selivanov added the comment: I think that's a bad API, it should be agnostic about the implementation language. Agree. Re #20711: Please take a look at the patch I wrote. It's your code I modified, you know it and the __text_signature__ quirks better than anyone. --

[issue20710] Make pydoc consistent about bound methods

2014-02-20 Thread Larry Hastings
Larry Hastings added the comment: Here's a revised patch that doesn't modify inspect. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20710 ___

[issue20710] Make pydoc consistent about bound methods

2014-02-20 Thread Larry Hastings
Changes by Larry Hastings la...@hastings.org: Added file: http://bugs.python.org/file34165/larry.fix.help.on.bound.methods.3.diff ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20710 ___

[issue20710] Make pydoc consistent about bound methods

2014-02-20 Thread Larry Hastings
Larry Hastings added the comment: A slight tweak to the patch. Previously I was just using truth testing on the value I got from __self__, but that's wrong if the object is considered false (e.g. ''.zfill). (Yury got this right in #20711, and I copied from him!) -- Added file:

[issue20710] Make pydoc consistent about bound methods

2014-02-20 Thread Larry Hastings
Larry Hastings added the comment: An even slighter tweak to the patch, just using De Morgan's law to make the code easier to read. -- Added file: http://bugs.python.org/file34168/larry.fix.help.on.bound.methods.5.diff ___ Python tracker

[issue20710] Make pydoc consistent about bound methods

2014-02-20 Thread Larry Hastings
Larry Hastings added the comment: Updated with tests. And I built without docstrings and it still passed. And if I revert the change to Lib/pydoc.py the tests fail. -- Added file: http://bugs.python.org/file34170/larry.fix.help.on.bound.methods.6.diff

[issue20710] Make pydoc consistent about bound methods

2014-02-20 Thread Larry Hastings
Larry Hastings added the comment: I went ahead and added tests for os.stat, and the unbound versions of the two class methods. Total of five new tests now. -- Added file: http://bugs.python.org/file34171/larry.fix.help.on.bound.methods.7.diff ___

[issue20710] Make pydoc consistent about bound methods

2014-02-20 Thread Larry Hastings
Larry Hastings added the comment: You're right, that was the exact same test ;-) So what I did was: move the other tests down into that test class, as that's a better fit, and keep the new version of the test. -- Added file:

[issue20710] Make pydoc consistent about bound methods

2014-02-20 Thread Yury Selivanov
Yury Selivanov added the comment: Looks good to me. Those unit tests give some confidence ;) -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20710 ___

[issue20710] Make pydoc consistent about bound methods

2014-02-20 Thread Roundup Robot
Roundup Robot added the comment: New changeset 5e73bb72662e by Larry Hastings in branch 'default': Issue #20710: The pydoc summary line no longer displays the self parameter http://hg.python.org/cpython/rev/5e73bb72662e -- nosy: +python-dev ___

[issue20710] Make pydoc consistent about bound methods

2014-02-20 Thread Larry Hastings
Changes by Larry Hastings la...@hastings.org: -- resolution: - fixed stage: patch review - committed/rejected status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20710 ___

[issue20710] Make pydoc consistent about bound methods

2014-02-20 Thread Yury Selivanov
Yury Selivanov added the comment: With this patch 'help' now correctly renders classmethods, yay -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20710 ___