Torim added the comment:

I would add even the linked solution from StackOverflow.com does not work 
reliably for me. Try to get at the end of numpy document - text vanishes and 
possibly lose chars displaying in terminal. Need to reset it.

Modified pydoc's pipepager method this way:
def pipepager(text, cmd):
    """Page through text by feeding it to another program."""
    #pipe = os.popen(cmd, 'w')
    import subprocess
    pipep = subprocess.Popen(cmd, stdin=subprocess.PIPE, shell=True)
    try:
        #pipe.write(text)
        #pipe.close()
        pipep.communicate(text)
    except IOError:
        pass # Ignore broken pipes caused by quitting the pager program.


Works for me so far, although the exact cause of issue with the stock/default 
pydoc is still not known.

----------
components: +Library (Lib)
nosy: +torim

_______________________________________
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue18356>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to