python-utils 3.8.0__py2.py3-none-any.whl → 3.8.2__py2.py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
python_utils/__about__.py CHANGED
@@ -7,4 +7,4 @@ __description__: str = (
7
7
  )
8
8
  __url__: str = 'https://github.com/WoLpH/python-utils'
9
9
  # Omit type info due to automatic versioning script
10
- __version__ = '3.8.0'
10
+ __version__ = '3.8.2'
@@ -312,28 +312,28 @@ class UniqueList(types.List[HT]):
312
312
 
313
313
  # Type hinting `collections.deque` does not work consistently between Python
314
314
  # runtime, mypy and pyright currently so we have to ignore the errors
315
- class SlicableDeque(types.Generic[T], collections.deque): # type: ignore
315
+ class SliceableDeque(types.Generic[T], collections.deque): # type: ignore
316
316
  @typing.overload
317
317
  def __getitem__(self, index: types.SupportsIndex) -> T:
318
318
  ...
319
319
 
320
320
  @typing.overload
321
- def __getitem__(self, index: slice) -> 'SlicableDeque[T]':
321
+ def __getitem__(self, index: slice) -> 'SliceableDeque[T]':
322
322
  ...
323
323
 
324
324
  def __getitem__(
325
325
  self, index: types.Union[types.SupportsIndex, slice]
326
- ) -> types.Union[T, 'SlicableDeque[T]']:
326
+ ) -> types.Union[T, 'SliceableDeque[T]']:
327
327
  '''
328
328
  Return the item or slice at the given index.
329
329
 
330
- >>> d = SlicableDeque[int]([1, 2, 3, 4, 5])
330
+ >>> d = SliceableDeque[int]([1, 2, 3, 4, 5])
331
331
  >>> d[1:4]
332
- SlicableDeque([2, 3, 4])
332
+ SliceableDeque([2, 3, 4])
333
333
 
334
- >>> d = SlicableDeque[str](['a', 'b', 'c'])
334
+ >>> d = SliceableDeque[str](['a', 'b', 'c'])
335
335
  >>> d[-2:]
336
- SlicableDeque(['b', 'c'])
336
+ SliceableDeque(['b', 'c'])
337
337
 
338
338
  '''
339
339
  if isinstance(index, slice):
python_utils/time.py CHANGED
@@ -130,7 +130,7 @@ def format_time(
130
130
 
131
131
  try: # pragma: no cover
132
132
  dt = datetime.datetime.fromtimestamp(seconds)
133
- except ValueError: # pragma: no cover
133
+ except (ValueError, OSError): # pragma: no cover
134
134
  dt = datetime.datetime.max
135
135
  return str(dt)
136
136
  elif isinstance(timestamp, datetime.date):
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: python-utils
3
- Version: 3.8.0
3
+ Version: 3.8.2
4
4
  Summary: Python Utils is a module with some convenient utilities not included with the standard Python install
5
5
  Home-page: https://github.com/WoLpH/python-utils
6
6
  Author: Rick van Hattem
@@ -1,8 +1,8 @@
1
- python_utils/__about__.py,sha256=3nuF5UaTLscLy-5HWEtCNo_l2wjjjNpK9EI6QUkPkMk,385
1
+ python_utils/__about__.py,sha256=jnOBCh5mtrcmw0FmS2-tji0DOlMBO7n9MQUk3SxuFKM,385
2
2
  python_utils/__init__.py,sha256=HGz7pZnS6QesK0SomLOgHnA2ldA8yFZoV3m8qwlPBks,1705
3
3
  python_utils/aio.py,sha256=HCcfWm82qzQvwMGbO5MwCiLZMW1WLT28TksLV-45d78,1291
4
4
  python_utils/compat.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
5
- python_utils/containers.py,sha256=w4ibvk4yCAS_d12haxZRxbF94KvYMhjrWz7IToKPjoY,10795
5
+ python_utils/containers.py,sha256=QBO0GNAJ-W_Ox0ElAjK49Rs3OtB3MAyV-Nq5dpALLKU,10802
6
6
  python_utils/converters.py,sha256=4yainms6NUWITUxq-ajJUenT5I0zN1G9XZlxpGsrUVc,11404
7
7
  python_utils/decorators.py,sha256=L6BdW94YdW4Wfgwa5aRlqYRpcAxq3Olo4mutexbKkuY,5390
8
8
  python_utils/exceptions.py,sha256=iUOxIz5OGPRJcqr6afgwuIZ-i_expS5UyMxpVs8WP3I,617
@@ -13,10 +13,10 @@ python_utils/logger.py,sha256=hnog07avWLkAIfMGbaP5ri_YAuv00psj-z73ha5zrH8,6371
13
13
  python_utils/loguru.py,sha256=jbAr6SVavrsH4nAicJstLtLTs50S7w5HWeWHzIOLw54,358
14
14
  python_utils/py.typed,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
15
15
  python_utils/terminal.py,sha256=FbuYoWohCTllBheaTjOVvkbkj9gFbXF0-Zq4Z0updKA,4711
16
- python_utils/time.py,sha256=xc6D9MLy10tRWBof6koePIMNs7eRTOVauyitWwsOkXI,11304
16
+ python_utils/time.py,sha256=p0Raohyhl-5Psul-P3DHI6p8EbWB9LQUDIlOP9UMfj4,11315
17
17
  python_utils/types.py,sha256=75p6yXn771yfHHzbBWGrPCYmqqrme1beRurYWh4ltsg,3652
18
- python_utils-3.8.0.dist-info/LICENSE,sha256=_Zrs9NZu-G6_aZT2g3Jv5_JREJQfhRNBC61EH6WDH-o,1501
19
- python_utils-3.8.0.dist-info/METADATA,sha256=HfLBEoMQXrmHULOIm_6YGxvIm72ehayMQY8OOO19uPg,9650
20
- python_utils-3.8.0.dist-info/WHEEL,sha256=iYlv5fX357PQyRT2o6tw1bN-YcKFFHKqB_LwHO5wP-g,110
21
- python_utils-3.8.0.dist-info/top_level.txt,sha256=zAx6OfEsjJs8BEW3okSiG_j9gpkI69xWShzum6oBgKI,13
22
- python_utils-3.8.0.dist-info/RECORD,,
18
+ python_utils-3.8.2.dist-info/LICENSE,sha256=_Zrs9NZu-G6_aZT2g3Jv5_JREJQfhRNBC61EH6WDH-o,1501
19
+ python_utils-3.8.2.dist-info/METADATA,sha256=YEDzqBig3s7X5zy7rudSxoYAEniI_pogZvul1hnIe-I,9650
20
+ python_utils-3.8.2.dist-info/WHEEL,sha256=-G_t0oGuE7UD0DrSpVZnq1hHMBV9DD2XkS5v7XpmTnk,110
21
+ python_utils-3.8.2.dist-info/top_level.txt,sha256=zAx6OfEsjJs8BEW3okSiG_j9gpkI69xWShzum6oBgKI,13
22
+ python_utils-3.8.2.dist-info/RECORD,,
@@ -1,5 +1,5 @@
1
1
  Wheel-Version: 1.0
2
- Generator: bdist_wheel (0.41.2)
2
+ Generator: bdist_wheel (0.42.0)
3
3
  Root-Is-Purelib: true
4
4
  Tag: py2-none-any
5
5
  Tag: py3-none-any