Commit 803e73b5 authored by Guillaume Seguin's avatar Guillaume Seguin

Use logging in pronsole

parent 8b6ab209
...@@ -25,6 +25,7 @@ import codecs ...@@ -25,6 +25,7 @@ import codecs
import shlex import shlex
import argparse import argparse
import locale import locale
import logging
from . import printcore from . import printcore
from printrun.printrun_utils import install_locale from printrun.printrun_utils import install_locale
...@@ -402,7 +403,7 @@ class pronsole(cmd.Cmd): ...@@ -402,7 +403,7 @@ class pronsole(cmd.Cmd):
print u"".join(unicode(i) for i in msg) print u"".join(unicode(i) for i in msg)
def logError(self, *msg): def logError(self, *msg):
print u"".join(unicode(i) for i in msg) logging.error(u"".join(unicode(i) for i in msg))
def promptf(self): def promptf(self):
"""A function to generate prompts so that we can do dynamic prompts. """ """A function to generate prompts so that we can do dynamic prompts. """
...@@ -1551,4 +1552,3 @@ class pronsole(cmd.Cmd): ...@@ -1551,4 +1552,3 @@ class pronsole(cmd.Cmd):
readline.set_completer(self.old_completer) readline.set_completer(self.old_completer)
except ImportError: except ImportError:
pass pass
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment