Skip to content

Commit 5d8f28b

Browse files
committed
fix crash on funcs with no docstring
1 parent 910e310 commit 5d8f28b

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

bpython/cli.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -638,6 +638,8 @@ def _complete(self, unused_tab=False):
638638
return False
639639
if self.current_func is not None:
640640
self.docstring = pydoc.getdoc(self.current_func)
641+
if not self.docstring:
642+
self.docstring = None
641643

642644
if not e and matches:
643645
# remove duplicates and restore order

0 commit comments

Comments
 (0)