(v)
| 225 | |
| 226 | |
| 227 | def str2bool(v): |
| 228 | if isinstance(v, bool): |
| 229 | return v |
| 230 | if v.lower() in ('yes', 'true', 't', 'y', '1'): |
| 231 | return True |
| 232 | elif v.lower() in ('no', 'false', 'f', 'n', '0'): |
| 233 | return False |
| 234 | else: |
| 235 | raise argparse.ArgumentTypeError('Boolean value expected.') |
| 236 | |
| 237 | |
| 238 | if __name__ == "__main__": |
nothing calls this directly
no outgoing calls
no test coverage detected