diff options
Diffstat (limited to 'pym')
-rw-r--r-- | pym/output.py | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/pym/output.py b/pym/output.py index 42e581159..ab2227574 100644 --- a/pym/output.py +++ b/pym/output.py @@ -256,6 +256,8 @@ def get_term_size(): occurs. The curses module is used if available, otherwise the output of `stty size` is parsed. """ + if not sys.stdout.isatty(): + return -1, -1 try: import curses try: |