Skip to content

Commit 5f070f4

Browse files
committed
Initialize width/height using os.get_terminal_size
1 parent 43778e8 commit 5f070f4

File tree

1 file changed

+1
-3
lines changed

1 file changed

+1
-3
lines changed

bpython/curtsiesfrontend/repl.py

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,6 @@
1919
Optional,
2020
Tuple,
2121
Union,
22-
cast,
2322
Type,
2423
)
2524
from .._typing_compat import Literal
@@ -465,8 +464,7 @@ def __init__(
465464

466465
# as long as the first event received is a window resize event,
467466
# this works fine...
468-
self.width: int = cast(int, None)
469-
self.height: int = cast(int, None)
467+
self.width, self.height = os.get_terminal_size()
470468

471469
self.status_bar.message(banner)
472470

0 commit comments

Comments
 (0)