diff options
| author | Scott Gasch <[email protected]> | 2022-02-06 13:45:21 -0800 |
|---|---|---|
| committer | Scott Gasch <[email protected]> | 2022-02-06 13:45:21 -0800 |
| commit | b22b39493c5b6c747b16e9430f3833bb8869cef6 (patch) | |
| tree | c494285c0b302d95ef7b428d026a72d268d1d0b6 /string_utils.py | |
| parent | d2376b4dd7a8bba0dfc878578086faeab83c6f5b (diff) | |
Add a simple test for waitable presence.
Diffstat (limited to 'string_utils.py')
| -rw-r--r-- | string_utils.py | 22 |
1 files changed, 11 insertions, 11 deletions
diff --git a/string_utils.py b/string_utils.py index 3ae9eea..ec662d2 100644 --- a/string_utils.py +++ b/string_utils.py @@ -142,16 +142,16 @@ MARGIN_RE = re.compile(r"^[^\S\r\n]+") ESCAPE_SEQUENCE_RE = re.compile(r"\[[^A-Za-z]*[A-Za-z]") NUM_SUFFIXES = { - "Pb": (1024 ** 5), - "P": (1024 ** 5), - "Tb": (1024 ** 4), - "T": (1024 ** 4), - "Gb": (1024 ** 3), - "G": (1024 ** 3), - "Mb": (1024 ** 2), - "M": (1024 ** 2), - "Kb": (1024 ** 1), - "K": (1024 ** 1), + "Pb": (1024**5), + "P": (1024**5), + "Tb": (1024**4), + "T": (1024**4), + "Gb": (1024**3), + "G": (1024**3), + "Mb": (1024**2), + "M": (1024**2), + "Kb": (1024**1), + "K": (1024**1), } @@ -1075,7 +1075,7 @@ def to_date(in_str: str) -> Optional[datetime.date]: """ Parses a date string. See DateParser docs for details. """ - import dateparse.dateparse_utils as dp # type: ignore + import dateparse.dateparse_utils as dp try: d = dp.DateParser() |
