[PATCH 4/4] Remove the last usage of newt and get rid of it as a dependency

Vratislav Podzimek vpodzime at redhat.com
Fri Jun 19 11:11:55 UTC 2015


With the new rescue mode it's not really worth it to keep using snack/newt to
let users know they cannot continue because of not enough RAM being availaible
and requiring. We can use simple prints and get rid of the python-newt
dependency.

Signed-off-by: Vratislav Podzimek <vpodzime at redhat.com>
---
 anaconda         | 10 ++++------
 anaconda.spec.in |  3 ---
 2 files changed, 4 insertions(+), 9 deletions(-)

diff --git a/anaconda b/anaconda
index 6c3fb56..2dca2a5 100755
--- a/anaconda
+++ b/anaconda
@@ -504,18 +504,16 @@ def check_memory(anaconda, options, display_mode=None):
                    "needed_ram": needed_ram,
                    "total_ram": total_ram}
     if needed_ram > total_ram:
-        from snack import SnackScreen, ButtonChoiceWindow
         if options.liveinst:
             # pylint: disable=logging-not-lazy
             stdoutLog.warning(reason % reason_args)
             gtk_warning(livecd_title, reason % reason_args)
         else:
             reason += reboot_extra
-            screen = SnackScreen()
-            ButtonChoiceWindow(screen, _('Fatal Error'),
-                               reason % reason_args,
-                               buttons = (_("OK"),))
-            screen.finish()
+            print(reason % reason_args)
+            print(_("The installation cannot continue and the system will be rebooted"))
+            print(_("Press ENTER to continue"))
+            input()
 
         iutil.ipmi_report(constants.IPMI_ABORTED)
         sys.exit(1)
diff --git a/anaconda.spec.in b/anaconda.spec.in
index 8c7a2ac..d2aa410 100644
--- a/anaconda.spec.in
+++ b/anaconda.spec.in
@@ -134,9 +134,6 @@ Requires: kexec-tools
 
 Requires: python3-coverage
 
-# Used by rescue.py and the low RAM message in /sbin/anaconda
-Requires: newt-python3
-
 # required because of the rescue mode and VNC question
 Requires: anaconda-tui = %{version}-%{release}
 
-- 
2.1.0



More information about the anaconda-patches mailing list