From 237502ae6be831ef3a0e644e234cd6b95cf46b17 Mon Sep 17 00:00:00 2001 From: Ozzieisaacs Date: Sat, 16 Feb 2019 10:18:32 +0100 Subject: [PATCH] Output of errormessage for invalid CALIBRE_PORT value --- cps/ub.py | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/cps/ub.py b/cps/ub.py index 698a3be8..f1f8f02d 100644 --- a/cps/ub.py +++ b/cps/ub.py @@ -64,10 +64,8 @@ DEFAULT_PASS = "admin123" try: DEFAULT_PORT = int(os.environ.get("CALIBRE_PORT", 8083)) except ValueError: - '''value = re.findall('.*?(\d+)$',os.environ.get("CALIBRE_PORT")) - if len(value): - DEFAULT_PORT = int(value[0]) - else:''' + print ('Environmentvariable CALIBRE_PORT is set to an invalid value: ' + + os.environ.get("CALIBRE_PORT", 8083) + ', faling back to default (8083)') DEFAULT_PORT = 8083 UPDATE_STABLE = 0