aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--rumba/log.py15
-rw-r--r--rumba/ssh_support.py2
2 files changed, 8 insertions, 9 deletions
diff --git a/rumba/log.py b/rumba/log.py
index d95c034..bed0170 100644
--- a/rumba/log.py
+++ b/rumba/log.py
@@ -40,9 +40,8 @@ class RumbaFormatter(logging.Formatter):
def __init__(self):
super(RumbaFormatter, self).__init__(
- fmt='{asctime} | {levelname:3.3} | '
- '{name:11.11} | {message}',
- style='{',
+ fmt='%(asctime)s | %(levelname)3.3s | '
+ '%(name)11.11s | %(message)s',
datefmt='%H:%M:%S')
def format(self, record):
@@ -95,11 +94,11 @@ def set_logging_level(level, name=None):
"""
Set the current logging level to <level> for logger named <name>.
If name is not specified, sets the logging level for all rumba loggers.
- Accepted levels are:
- DEBUG == 10,
- INFO == 20,
- WARNING == 30,
- ERROR == 40,
+ Accepted levels are:
+ DEBUG == 10,
+ INFO == 20,
+ WARNING == 30,
+ ERROR == 40,
CRITICAL == 50,
NOTSET == 0
(resets the logger: its level is set to the default or its parents' level)
diff --git a/rumba/ssh_support.py b/rumba/ssh_support.py
index a1e1ba4..b0970e1 100644
--- a/rumba/ssh_support.py
+++ b/rumba/ssh_support.py
@@ -40,7 +40,7 @@ def _print_stream(stream):
o_array = o.split('\\n')
for oi in o_array:
logger.debug(oi)
- return o
+ return o.rstrip()
def execute_proxy_commands(testbed, ssh_config, commands, time_out=3):