[anaconda][rhel7-branch/master][v2][PATCH] Don't attempt terminal size detection on the s390 (#1145065)

Martin Kolman mkolman at redhat.com
Mon Sep 22 17:05:40 UTC 2014


Resolves: rhbz#1145065
Signed-off-by: Martin Kolman <mkolman at redhat.com>
---
 pyanaconda/anaconda_argparse.py | 9 +++++++++
 1 file changed, 9 insertions(+)

diff --git a/pyanaconda/anaconda_argparse.py b/pyanaconda/anaconda_argparse.py
index c5dc78d..6ec230d 100644
--- a/pyanaconda/anaconda_argparse.py
+++ b/pyanaconda/anaconda_argparse.py
@@ -52,6 +52,15 @@ def get_help_width():
     :returns: optimal help text width in number of characters
     :rtype: integer
     """
+    # don't do terminal size detection on s390, it is not supported
+    # by its arcane TTY system and only results in cryptic error messages
+    # ending on the standard output
+    # (we do the s390 detection here directly to avoid
+    #  the delay caused by importing the Blivet module
+    #  just for this single call)
+    is_s390 = os.uname()[4].startswith('s390')
+    if is_s390:
+        return DEFAULT_HELP_WIDTH
 
     help_width = DEFAULT_HELP_WIDTH
     try:
-- 
1.9.3



More information about the anaconda-patches mailing list