From d5d036b412254a26e1fdcfebd939edb8e968a0de Mon Sep 17 00:00:00 2001 From: kevgliss Date: Tue, 22 Nov 2016 16:47:29 -0800 Subject: [PATCH] adding a work around for new gunicorn (#523) --- lemur/manage.py | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-) diff --git a/lemur/manage.py b/lemur/manage.py index f838e5bb..d3c915ca 100755 --- a/lemur/manage.py +++ b/lemur/manage.py @@ -364,10 +364,16 @@ class LemurServer(Command): def get_options(self): settings = make_settings() - options = ( - Option(*klass.cli, action=klass.action) - for setting, klass in settings.items() if klass.cli - ) + options = [] + for setting, klass in settings.items(): + if klass.cli: + if klass.action: + if klass.action == 'store_const': + options.append(Option(*klass.cli, const=klass.const, action=klass.action)) + else: + options.append(Option(*klass.cli, action=klass.action)) + else: + options.append(Option(*klass.cli)) return options