summaryrefslogtreecommitdiff
path: root/jfr_playoff/settings.py
diff options
context:
space:
mode:
authorMichał Klichowicz <emkael@tlen.pl>2024-04-13 13:17:56 +0200
committerMichał Klichowicz <emkael@tlen.pl>2024-04-13 13:17:56 +0200
commit40eaf8435414c6f0a3c7968942b90b5fa85f4d44 (patch)
tree3434b04818020210cc08de3c75a8e16695ee7a66 /jfr_playoff/settings.py
parentf83effb4242a9230b30ec1177bc61bf921b3b45b (diff)
In a console-less setup, e.g. GUI, revert to any sane log encoding
Fixes #55
Diffstat (limited to 'jfr_playoff/settings.py')
-rw-r--r--jfr_playoff/settings.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/jfr_playoff/settings.py b/jfr_playoff/settings.py
index b12ffef..d997e42 100644
--- a/jfr_playoff/settings.py
+++ b/jfr_playoff/settings.py
@@ -4,7 +4,7 @@ import readline
import requests
import sys
-from jfr_playoff.logger import PlayoffLogger
+from jfr_playoff.logger import PlayoffLogger, log_encoding
def complete_filename(text, state):
@@ -47,7 +47,7 @@ class PlayoffSettings(object):
readline.parse_and_bind("tab: complete")
readline.set_completer(complete_filename)
self.settings_file = raw_input(
- 'JSON settings file: ').decode(sys.stdin.encoding)
+ 'JSON settings file: ').decode(log_encoding())
if self.settings is None:
PlayoffLogger.get('settings').info(