From 1968b5212a2eed6ce374a34fafd6f399ca38e66d 2008-02-21 17:35:34 From: Ville M. Vainio Date: 2008-02-21 17:35:34 Subject: [PATCH] %quickref crashed if a magic function has no docstring --- diff --git a/IPython/Magic.py b/IPython/Magic.py index b43f604..6f5c79e 100644 --- a/IPython/Magic.py +++ b/IPython/Magic.py @@ -409,7 +409,10 @@ license. To use profiling, please install"python2.3-profiler" from non-free.""") break if mode == 'brief': # only first line - fndoc = fn.__doc__.split('\n',1)[0] + if fn.__doc__: + fndoc = fn.__doc__.split('\n',1)[0] + else: + fndoc = 'No documentation' else: fndoc = fn.__doc__