X-Git-Url: https://wannabe.guru.org/gitweb/?a=blobdiff_plain;f=argparse_utils.py;h=e8c2f5699bea4bceb67d22127a923099d0d143e5;hb=e8671a716da868332d3ac1f66d4d2f7f8d33fc28;hp=2d2297ccf2f8e7f9df99929925ab1b973ee5c44b;hpb=5e1bced276766fec9d4c408790c99d4a26d267e0;p=python_utils.git diff --git a/argparse_utils.py b/argparse_utils.py index 2d2297c..e8c2f56 100644 --- a/argparse_utils.py +++ b/argparse_utils.py @@ -6,6 +6,9 @@ import logging import os from typing import Any +from overrides import overrides + + # This module is commonly used by others in here and should avoid # taking any unnecessary dependencies back on them. @@ -47,6 +50,7 @@ class ActionNoYes(argparse.Action): help=help ) + @overrides def __call__(self, parser, namespace, values, option_strings=None): if ( option_strings.startswith('--no-') or @@ -242,7 +246,7 @@ def valid_duration(txt: str) -> datetime.timedelta: datetime.timedelta(seconds=180) >>> valid_duration('your mom') - datetime.timedelta(seconds=0) + datetime.timedelta(0) """ from datetime_utils import parse_duration