(v)
| 253 | |
| 254 | |
| 255 | def str2bool(v): |
| 256 | if isinstance(v, bool): |
| 257 | return v |
| 258 | if v.lower() in ('yes', 'true', 't', 'y', '1'): |
| 259 | return True |
| 260 | elif v.lower() in ('no', 'false', 'f', 'n', '0'): |
| 261 | return False |
| 262 | else: |
| 263 | raise argparse.ArgumentTypeError('Boolean value expected.') |
| 264 | |
| 265 | |
| 266 | if __name__ == "__main__": |
nothing calls this directly
no outgoing calls
no test coverage detected