summaryrefslogtreecommitdiffstats
path: root/text.py
diff options
context:
space:
mode:
authorChris Lumens <clumens@redhat.com>2005-08-11 21:10:55 +0000
committerChris Lumens <clumens@redhat.com>2005-08-11 21:10:55 +0000
commitbe9b1d17b23f3075f12a939cc7d11fe8687edcc9 (patch)
tree2976ab4680cdf62106006ca7d5e7dd5d2ad9109e /text.py
parent3fe2eaa6f45decc83d76c4ec15e8b6c53275cfca (diff)
downloadanaconda-be9b1d17b23f3075f12a939cc7d11fe8687edcc9.tar.gz
anaconda-be9b1d17b23f3075f12a939cc7d11fe8687edcc9.tar.xz
anaconda-be9b1d17b23f3075f12a939cc7d11fe8687edcc9.zip
Converted a lot more messages to the new logging system, but there's still
41 files to go. If your favorite log message needs to be on a different priority level, feel free to change it. Maybe we can have little commit wars over them.
Diffstat (limited to 'text.py')
-rw-r--r--text.py16
1 files changed, 9 insertions, 7 deletions
diff --git a/text.py b/text.py
index fa512b76b..b56874c1e 100644
--- a/text.py
+++ b/text.py
@@ -29,9 +29,11 @@ from flags import flags
from constants_text import *
from constants import *
-from rhpl.log import log
from rhpl.translate import _, cat, N_
+import logging
+log = logging.getLogger("anaconda")
+
stepToClasses = {
"language" : ("language_text", "LanguageWindow"),
"keyboard" : ("keyboard_text", "KeyboardWindow"),
@@ -313,7 +315,7 @@ class InstallInterface:
# in our code and avoid popping up the exception window here.
if exc.options == parted.EXCEPTION_CANCEL:
return parted.EXCEPTION_UNHANDLED
- log("parted exception: %s: %s" %(exc.type_string,exc.message))
+ log.critical("parted exception: %s: %s" %(exc.type_string,exc.message))
buttons = []
buttonToAction = {}
flags = ((parted.EXCEPTION_FIX, N_("Fix")),
@@ -379,23 +381,23 @@ class InstallInterface:
(id.instLanguage.getFontFile(id.instLanguage.getCurrent()) == "bterm")
and not flags.serial and not flags.virtpconsole
and not isys.isPsudoTTY(0) and not isys.isVioConsole()):
- log("starting bterm")
+ log.info("starting bterm")
rc = 1
try:
rc = isys.startBterm()
time.sleep(1)
except Exception, e:
- log("got an exception starting bterm: %s" %(e,))
+ log.critical("got an exception starting bterm: %s" %(e,))
if rc == 1:
- log("unable to start bterm, falling back to english")
+ log.warning("unable to start bterm, falling back to english")
oldlang = id.instLanguage.getCurrent()
- log("old language was %s" %(oldlang,))
+ log.warning("old language was %s" %(oldlang,))
id.instLanguage.setRuntimeLanguage("en_US.UTF-8")
id.instLanguage.setRuntimeDefaults(oldlang)
if id.instLanguage.getFontFile(id.instLanguage.getCurrent()) == "none":
- log("run: setting default runtime language")
+ log.info("run: setting default runtime language")
oldlang = id.instLanguage.getCurrent()
id.instLanguage.setRuntimeLanguage("en_US.UTF-8")
id.instLanguage.setRuntimeDefaults(oldlang)