aboutsummaryrefslogtreecommitdiffstats
path: root/epy.py
diff options
context:
space:
mode:
authorbenadha <benawiadha@gmail.com>2022-01-08 13:13:58 +0700
committerbenadha <benawiadha@gmail.com>2022-01-08 13:13:58 +0700
commit69c2f80ef3d8be3e986d3f8528550263afb62159 (patch)
treeddad3b07fff1ca25646fe94cd7111a62a1ed15a8 /epy.py
parent16a6ba5c634eefb832a4bfcf5c0d2f2742c667b1 (diff)
downloadepy-69c2f80ef3d8be3e986d3f8528550263afb62159.tar.gz
Hotfix: curses has no attrib window in termux
Diffstat (limited to 'epy.py')
-rwxr-xr-xepy.py8
1 files changed, 4 insertions, 4 deletions
diff --git a/epy.py b/epy.py
index 36d8760..e5050d9 100755
--- a/epy.py
+++ b/epy.py
@@ -64,11 +64,11 @@ try:
# $ DEBUG=1 ./epy.py
DEBUG = int(str(os.getenv("DEBUG"))) == 1
- STDSCR: Optional[curses.window] = None
+ STDSCR = None
def debug(context: int = 5) -> None:
- if not isinstance(STDSCR, curses.window):
- raise RuntimeError("STDSCR not set")
+ # if not isinstance(STDSCR, curses.window):
+ # raise RuntimeError("STDSCR not set")
curses.nocbreak()
STDSCR.keypad(False)
curses.echo()
@@ -3554,7 +3554,7 @@ class Reader:
sys.exit()
-def preread(stdscr: curses.window, filepath: str):
+def preread(stdscr, filepath: str):
global STDSCR
if DEBUG:
STDSCR = stdscr