You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When the terminal VisiData is running in is resized to a height of 1, it immediately exits with a code of 255.
Steps to reproduce
Run vd
Resize height of terminal window to 1
Expected result
VisiData shouldn't crash and when the terminal is resized to its original size it should continue running just like other programs likes less or top or nvim.
Actual result with screenshot
(nothing interesting here, no error messages are printed or anything)
Configuration
Does this issue reproduce without any plugins or configuration (using the -N CLI flag)?
Thanks for catching this case. When visidata exits silently from a caught exception, you can see the exception by running with debug mode turned on: vd --debug.
In this case, with tmux with a pane of height 1, I see exceptions from trying to make subwindows with height < 0 or y > height:
File "/home/midichef/.local/lib/python3.10/site-packages/visidata/basesheet.py", line 313, in redraw
vd.setWindows(vd.scrFull)
File "/home/midichef/.local/lib/python3.10/site-packages/visidata/mainloop.py", line 84, in setWindows
vd.winTop = vd.subwindow(scr, 0, topmenulines, w, n)
File "/home/midichef/.local/lib/python3.10/site-packages/visidata/tuiwin.py", line 9, in subwindow
newscr = scr.derwin(h, w, y, x)
_curses.error: curses function returned NULL
I'll submit a PR that puts range restrictions on the coordinates and dimensions.
(Incidentally, debug mode is inappropriate for everyday use as it can shut vd down at the first exception, even when you might prefer vd to continue.)
Small description
When the terminal VisiData is running in is resized to a height of 1, it immediately exits with a code of 255.
Steps to reproduce
vd
Expected result
VisiData shouldn't crash and when the terminal is resized to its original size it should continue running just like other programs likes
less
ortop
ornvim
.Actual result with screenshot
(nothing interesting here, no error messages are printed or anything)
Configuration
-N
CLI flag)?Yes.
I am using version
saul.pw/VisiData v3.1.1
Additional context
Linux and MacOS.
3.10.12
iTerm2
withtmux
running in it. I constantly resize tmux panes down to a height of 1 and then restore the size.The text was updated successfully, but these errors were encountered: