diff --git a/python/iridium_extractor_flowgraph.py b/python/iridium_extractor_flowgraph.py index 6d84482..1e01ce2 100644 --- a/python/iridium_extractor_flowgraph.py +++ b/python/iridium_extractor_flowgraph.py @@ -13,7 +13,15 @@ import time import platform import multiprocessing -import distutils.util + +def strtobool(val): + val = val.lower() + if val in ('y', 'yes', 't', 'true', 'on', '1'): + return True + elif val in ('n', 'no', 'f', 'false', 'off', '0'): + return False + else: + raise ValueError("invalid truth value %r" % (val,)) class FlowGraph(gr.top_block): @@ -312,7 +320,7 @@ def match_gain(gain, gain_names): pass_tags = False if 'pass_tags' in d: - pass_tags = bool(distutils.util.strtobool(d['pass_tags'])) + pass_tags = strtobool(d['pass_tags']) timeout = 100 if 'timeout' in d: