[issue9118] help() on a property descriptor launches interactive help

2011-01-11 Thread Alexander Belopolsky
Alexander Belopolsky added the comment: Backported to 3.1 (r87934) and 2.7 (r87935). -- resolution: accepted -> fixed status: open -> closed ___ Python tracker ___ __

[issue9118] help() on a property descriptor launches interactive help

2010-07-04 Thread Terry J. Reedy
Terry J. Reedy added the comment: The doc says that help takes one optional arg: No arg: interactive help system String: interpret as name of something Any other object: help page for that object [by implication, multiple args: TypeError] Not returning help for None is a bug, so I say yes, back

[issue9118] help() on a property descriptor launches interactive help

2010-07-04 Thread Alexander Belopolsky
Alexander Belopolsky added the comment: Committed in r82547. I am leaving it open to decide whether this is a 3.1-backport candidate. Also I am not sure this is NEWS-worthy. Jack, Does this address your issue? Note that >>> help(X.foo.fset) will still not return help on X.foo, but it wi

[issue9118] help() on a property descriptor launches interactive help

2010-07-03 Thread Alexander Belopolsky
Alexander Belopolsky added the comment: Yes, I realized that 2+ arguments would be equivalent to none, but was too lazy to handle that case. (Falling into interactive help may actually be better than an error message for some users.) Terry's solution is certainly better. Attaching issue9118a

[issue9118] help() on a property descriptor launches interactive help

2010-07-03 Thread Terry J. Reedy
Terry J. Reedy added the comment: I agree that help(None) should return help on None but suggest a change to the patch. I understand that the point of changing -def __call__(self, request=None): to the somewhat opaque +def __call__(self, *args): +try: +request, = ar

[issue9118] help() on a property descriptor launches interactive help

2010-06-30 Thread Alexander Belopolsky
Alexander Belopolsky added the comment: This is simply because X.foo.fset is None and help(None) is the same as help(). Now, I think help(None) should print help on None object rather than start interactive help. Please consider attached patch. -- keywords: +patch nosy: +belopolsky

[issue9118] help() on a property descriptor launches interactive help

2010-06-29 Thread Jack Diederich
New submission from Jack Diederich : ython 2.7b2+ (trunk:81337, May 19 2010, 12:16:22) [GCC 4.4.3] on linux2 Type "help", "copyright", "credits" or "license" for more information. >>> class X(object): ... @property ... def foo(self): pass ... >>> help(X.foo.fset) Welcome to Python 2.7! Th