electrum

Electrum Bitcoin wallet
git clone https://git.parazyd.org/electrum
Log | Files | Refs | Submodules

commit 2598e89d00b6d82a514d79528e8d8341337e12f9
parent d66673eca2b0637aea925798316bf9b31e11cb76
Author: Amir Taaki <genjix@riseup.net>
Date:   Sat, 18 Aug 2012 09:35:02 +0100

More Pythonics util.print_error

Diffstat:
Mlib/gui_lite.py | 2+-
Mlib/util.py | 7+++----
2 files changed, 4 insertions(+), 5 deletions(-)

diff --git a/lib/gui_lite.py b/lib/gui_lite.py @@ -491,7 +491,7 @@ class MiniActuator: try: theme_prefix, theme_path = self.themes[self.theme_name] except KeyError: - util.print_error("Theme not found! ", self.theme_name) + util.print_error("Theme not found!", self.theme_name) return QDir.setCurrent(os.path.join(theme_prefix, theme_path)) with open(rsrc("style.css")) as style_file: diff --git a/lib/util.py b/lib/util.py @@ -3,10 +3,9 @@ import platform import sys def print_error(*args): - """Print out the arguments to standard error.""" - for item in args: - sys.stderr.write(str(item)) - sys.stderr.write("\n") + # Stringify args + args = [str(item) for item in args] + sys.stderr.write(" ".join(args) + "\n") sys.stderr.flush() def appdata_dir():