bump version, move str_to_bool to api module
This commit is contained in:
@@ -15,20 +15,6 @@ from .sucks_const import *
|
||||
import logging
|
||||
LOGGER = logging.getLogger(__name__)
|
||||
|
||||
def str_to_bool_or_cert(s):
|
||||
if s == 'True' or s == True:
|
||||
return True
|
||||
elif s == 'False' or s == False:
|
||||
return False
|
||||
else:
|
||||
if not s == None:
|
||||
if os.path.exists(s): # User could provide a path to a CA Cert as well, which is useful for Bumper
|
||||
if os.path.isfile(s):
|
||||
return s
|
||||
else:
|
||||
raise ValueError("Certificate path provided is not a file - {}".format(s))
|
||||
raise ValueError("Cannot covert {} to a bool or certificate path".format(s))
|
||||
|
||||
class EventEmitter(object):
|
||||
"""A very simple event emitting system."""
|
||||
def __init__(self):
|
||||
|
||||
Reference in New Issue
Block a user