[issue984870] curses: getmaxyx() breaks when the window shrinks

Christian Hudon report at bugs.python.org
Mon Apr 14 22:39:37 CEST 2014


Christian Hudon added the comment:

I get the same traceback. The traceback happens only when the window is shrunk below the size specified in derwin(). It's easy to see this by changing the first and second arguments to the derwin call to something like 2, 2, and then you can resize the window to a much smaller size without getting this exception. (My curses.version is 2.2 also. Running on OSX Mavericks.)

The getmaxyx() function reports the correct size when the window is shrunk. Also note that the upstream bug has been closed, with the comment "Not seen in python 2.7".

So I think we can close this. Maybe we want to document the behavior of derwin() and related functions of raising _curses.error when the dimensions of the terminal are smaller than that of the window, though? (Or maybe raise a better exception?) That should probably be another bug report, though.

----------
nosy: +chrish42

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue984870>
_______________________________________


More information about the Python-bugs-list mailing list