typing.py 499 B

1234567891011121314151617181920212223
  1. import sys
  2. from typing import Any, AsyncGenerator, Generator, NewType, Tuple, Union, List, Dict, Type
  3. if sys.version_info >= (3, 8):
  4. from typing import TypedDict
  5. else:
  6. from typing_extensions import TypedDict
  7. SHA256 = NewType('sha_256_hash', str)
  8. CreateResult = Generator[str, None, None]
  9. AsyncResult = AsyncGenerator[str, None]
  10. Messages = List[Dict[str, str]]
  11. __all__ = [
  12. 'Any',
  13. 'AsyncGenerator',
  14. 'Generator',
  15. 'Tuple',
  16. 'TypedDict',
  17. 'SHA256',
  18. 'CreateResult',
  19. ]