danielutils 0.9.77__tar.gz → 0.9.80__tar.gz

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.
Files changed (183) hide show
  1. {danielutils-0.9.77/danielutils.egg-info → danielutils-0.9.80}/PKG-INFO +2 -2
  2. {danielutils-0.9.77 → danielutils-0.9.80}/README.md +1 -1
  3. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/abstractions/database/database.py +2 -2
  4. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/abstractions/multiprogramming/worker.py +3 -3
  5. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/abstractions/multiprogramming/worker_pool.py +5 -5
  6. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/abstractions/repl.py +5 -5
  7. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/better_builtins/typed_builtins/factory.py +6 -6
  8. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/better_builtins/typed_builtins/tlist.py +2 -2
  9. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/colors.py +1 -1
  10. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/conversions/main_conversions.py +9 -9
  11. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/conversions/specialized_conversions/to_int.py +3 -3
  12. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/data_structures/graph/graph.py +14 -14
  13. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/data_structures/graph/multinode.py +4 -4
  14. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/data_structures/queue/queue.py +3 -3
  15. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/data_structures/trees/binary_syntax_tree.py +4 -4
  16. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/date.py +2 -2
  17. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/decorators/atomic.py +1 -1
  18. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/decorators/attach.py +1 -1
  19. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/decorators/decorate_conditionally.py +1 -1
  20. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/decorators/limit_recursion.py +1 -1
  21. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/decorators/memo.py +4 -4
  22. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/decorators/overload.py +4 -4
  23. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/decorators/partially_implemented.py +1 -1
  24. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/decorators/timeout.py +1 -1
  25. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/decorators/total_ordering.py +5 -5
  26. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/decorators/validate.py +1 -1
  27. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/functions/areoneof.py +3 -3
  28. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/functions/isoftype.py +4 -3
  29. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/functions/isoneof.py +4 -4
  30. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/functions/multiloop.py +2 -2
  31. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/functions/types_subseteq.py +4 -4
  32. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/generators/generator_from_stream.py +1 -1
  33. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/generators/join_generators.py +5 -5
  34. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/internet.py +7 -7
  35. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/io_.py +35 -33
  36. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/math_/functions.py +1 -1
  37. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/math_/math_symbols.py +4 -4
  38. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/math_/polynomial/polinomial.py +6 -6
  39. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/metaclasses/interface.py +6 -6
  40. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/protocols/dictable.py +4 -4
  41. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/reflection/class_/class_reflection.py +9 -9
  42. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/reflection/function/function_reflections.py +3 -3
  43. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/reflection/interpreter/get_traceback.py +3 -3
  44. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/reflection/interpreter/python_version.py +3 -3
  45. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/reflection/interpreter/tracer.py +4 -4
  46. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/reflection/module/package_reflection.py +8 -8
  47. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/system/independent.py +14 -13
  48. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/text.py +8 -8
  49. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/tqdm_.py +4 -4
  50. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/university/databases/all.py +20 -20
  51. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/university/oop/observer.py +2 -2
  52. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/university/probability/conditional_variable/discrete/geometric.py +3 -3
  53. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/university/probability/operator.py +9 -9
  54. danielutils-0.9.80/danielutils/versioned_imports.py +12 -0
  55. {danielutils-0.9.77 → danielutils-0.9.80/danielutils.egg-info}/PKG-INFO +2 -2
  56. {danielutils-0.9.77 → danielutils-0.9.80}/pyproject.toml +1 -1
  57. danielutils-0.9.77/danielutils/versioned_imports.py +0 -21
  58. {danielutils-0.9.77 → danielutils-0.9.80}/LICENSE +0 -0
  59. {danielutils-0.9.77 → danielutils-0.9.80}/MANIFEST.in +0 -0
  60. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/__init__.py +0 -0
  61. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/abstractions/__init__.py +0 -0
  62. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/abstractions/database/__init__.py +0 -0
  63. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/abstractions/database/cached_database.py +0 -0
  64. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/abstractions/database/redis_database.py +0 -0
  65. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/abstractions/multiprogramming/__init__.py +0 -0
  66. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/abstractions/multiprogramming/multi_id.py +0 -0
  67. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/aliases.py +0 -0
  68. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/better_builtins/__init__.py +0 -0
  69. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/better_builtins/counter.py +0 -0
  70. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/better_builtins/frange.py +0 -0
  71. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/better_builtins/typed_builtins/__init__.py +0 -0
  72. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/better_builtins/typed_builtins/tdict.py +0 -0
  73. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/better_builtins/typed_builtins/tset.py +0 -0
  74. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/better_builtins/typed_builtins/ttuple.py +0 -0
  75. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/convenience.py +0 -0
  76. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/conversions/__init__.py +0 -0
  77. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/conversions/specialized_conversions/__init__.py +0 -0
  78. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/conversions/specialized_conversions/to_hex.py +0 -0
  79. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/data_structures/__init__.py +0 -0
  80. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/data_structures/comparer.py +0 -0
  81. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/data_structures/default_dict.py +0 -0
  82. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/data_structures/functions.py +0 -0
  83. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/data_structures/graph/__init__.py +0 -0
  84. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/data_structures/graph/binary_node.py +0 -0
  85. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/data_structures/graph/node.py +0 -0
  86. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/data_structures/heap/__init__.py +0 -0
  87. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/data_structures/heap/heap.py +0 -0
  88. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/data_structures/heap/max_heap.py +0 -0
  89. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/data_structures/heap/min_heap.py +0 -0
  90. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/data_structures/queue/__init__.py +0 -0
  91. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/data_structures/queue/atomic_queue.py +0 -0
  92. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/data_structures/queue/priority_queue.py +0 -0
  93. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/data_structures/stack.py +0 -0
  94. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/data_structures/trees/__init__.py +0 -0
  95. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/data_structures/trees/binary_tree.py +0 -0
  96. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/date_time.py +0 -0
  97. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/decorators/__init__.py +0 -0
  98. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/decorators/chain_decorators.py +0 -0
  99. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/decorators/delay_call.py +0 -0
  100. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/decorators/deprecate.py +0 -0
  101. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/decorators/final.py +0 -0
  102. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/decorators/processify.py +0 -0
  103. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/decorators/property.py +0 -0
  104. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/decorators/singleton.py +0 -0
  105. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/decorators/threadify.py +0 -0
  106. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/exceptions.py +0 -0
  107. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/functions/__init__.py +0 -0
  108. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/functions/check_foreach.py +0 -0
  109. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/functions/flatten.py +0 -0
  110. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/functions/powerset.py +0 -0
  111. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/functions/subseteq.py +0 -0
  112. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/generators/__init__.py +0 -0
  113. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/generators/conditional_generator.py +0 -0
  114. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/math_/__init__.py +0 -0
  115. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/math_/constants.py +0 -0
  116. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/math_/math_print.py +0 -0
  117. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/math_/polynomial/__init__.py +0 -0
  118. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/metaclasses/__init__.py +0 -0
  119. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/metaclasses/atomic_class_meta.py +0 -0
  120. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/metaclasses/implicit_data_deleter_meta.py +0 -0
  121. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/metaclasses/instance_cache_meta.py +0 -0
  122. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/metaclasses/overload_meta.py +0 -0
  123. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/mock_/__init__.py +0 -0
  124. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/mock_/mock_database.py +0 -0
  125. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/mock_/mock_module.py +0 -0
  126. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/path.py +0 -0
  127. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/print_.py +0 -0
  128. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/protocols/__init__.py +0 -0
  129. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/protocols/evaluable.py +0 -0
  130. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/py.typed +0 -0
  131. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/reflection/__init__.py +0 -0
  132. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/reflection/class_/__init__.py +0 -0
  133. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/reflection/file/__init__.py +0 -0
  134. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/reflection/file/file_reflection.py +0 -0
  135. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/reflection/function/__init__.py +0 -0
  136. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/reflection/interpreter/__init__.py +0 -0
  137. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/reflection/interpreter/callstack.py +0 -0
  138. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/reflection/interpreter/os_.py +0 -0
  139. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/reflection/interpreter/packages.py +0 -0
  140. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/reflection/interpreter/signals.py +0 -0
  141. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/reflection/module/__init__.py +0 -0
  142. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/reflection/module/module_reflections.py +0 -0
  143. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/snippets/__init__.py +0 -0
  144. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/snippets/try_get.py +0 -0
  145. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/system/__init__.py +0 -0
  146. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/system/windows/__init__.py +0 -0
  147. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/system/windows/utils/__init__.py +0 -0
  148. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/system/windows/utils/filetime.py +0 -0
  149. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/system/windows/win32_ctime.py +0 -0
  150. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/system/windows/windows.py +0 -0
  151. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/time.py +0 -0
  152. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/university/__init__.py +0 -0
  153. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/university/databases/__init__.py +0 -0
  154. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/university/oop/__init__.py +0 -0
  155. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/university/oop/strategy.py +0 -0
  156. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/university/probability/__init__.py +0 -0
  157. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/university/probability/conditional_variable/__init__.py +0 -0
  158. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/university/probability/conditional_variable/conditional_variable.py +0 -0
  159. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/university/probability/conditional_variable/continuous/__init__.py +0 -0
  160. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/university/probability/conditional_variable/discrete/__init__.py +0 -0
  161. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/university/probability/conditional_variable/discrete/bernoulli.py +0 -0
  162. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/university/probability/conditional_variable/discrete/binomial.py +0 -0
  163. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/university/probability/conditional_variable/discrete/conditional_from_discrete_probability_func.py +0 -0
  164. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/university/probability/conditional_variable/discrete/discrete.py +0 -0
  165. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/university/probability/conditional_variable/discrete/poisson.py +0 -0
  166. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/university/probability/conditional_variable/discrete/uniform.py +0 -0
  167. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/university/probability/distributions.py +0 -0
  168. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/university/probability/expressions/__init__.py +0 -0
  169. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/university/probability/expressions/accumulation_expression.py +0 -0
  170. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/university/probability/expressions/probability_expression.py +0 -0
  171. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/university/probability/funcs/__init__.py +0 -0
  172. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/university/probability/funcs/covariance.py +0 -0
  173. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/university/probability/funcs/expected_value.py +0 -0
  174. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/university/probability/funcs/probability_function.py +0 -0
  175. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/university/probability/funcs/variance.py +0 -0
  176. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/university/probability/protocols.py +0 -0
  177. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/university/probability/supp.py +0 -0
  178. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils/university/probability/transformation.py +0 -0
  179. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils.egg-info/SOURCES.txt +0 -0
  180. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils.egg-info/dependency_links.txt +0 -0
  181. {danielutils-0.9.77 → danielutils-0.9.80}/danielutils.egg-info/top_level.txt +0 -0
  182. {danielutils-0.9.77 → danielutils-0.9.80}/setup.cfg +0 -0
  183. {danielutils-0.9.77 → danielutils-0.9.80}/setup.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: danielutils
3
- Version: 0.9.77
3
+ Version: 0.9.80
4
4
  Summary: A python utils library for things I find useful
5
5
  Author-email: danielnachumdev <danielnachumdev@gmail.com>
6
6
  License: MIT License
@@ -41,7 +41,7 @@ License-File: LICENSE
41
41
  [![Python 3.10.11](https://img.shields.io/badge/python-3.10.11-blue.svg)](https://www.python.org/downloads/release/python-31011/)
42
42
  [![gitleaks](https://github.com/danielnachumdev/danielutils/actions/workflows/gitleaks.yml/badge.svg)](https://github.com/danielnachumdev/danielutils/actions/workflows/gitleaks.yml)
43
43
  [![CodeQL](https://github.com/danielnachumdev/danielutils/actions/workflows/github-code-scanning/codeql/badge.svg)](https://github.com/danielnachumdev/danielutils/actions/workflows/github-code-scanning/codeql)
44
- # danielutils v=0.9.75
44
+ # danielutils v=0.9.80
45
45
  A utils library for things that I find useful for my coding workflow.\
46
46
  Feel free to use and / or contribute / improve my code :)
47
47
 
@@ -4,7 +4,7 @@
4
4
  [![Python 3.10.11](https://img.shields.io/badge/python-3.10.11-blue.svg)](https://www.python.org/downloads/release/python-31011/)
5
5
  [![gitleaks](https://github.com/danielnachumdev/danielutils/actions/workflows/gitleaks.yml/badge.svg)](https://github.com/danielnachumdev/danielutils/actions/workflows/gitleaks.yml)
6
6
  [![CodeQL](https://github.com/danielnachumdev/danielutils/actions/workflows/github-code-scanning/codeql/badge.svg)](https://github.com/danielnachumdev/danielutils/actions/workflows/github-code-scanning/codeql)
7
- # danielutils v=0.9.75
7
+ # danielutils v=0.9.80
8
8
  A utils library for things that I find useful for my coding workflow.\
9
9
  Feel free to use and / or contribute / improve my code :)
10
10
 
@@ -1,5 +1,5 @@
1
1
  from abc import ABC, abstractmethod
2
- from typing import Any, TypeVar, Generic, Optional
2
+ from typing import Any, TypeVar, Generic, Optional, Set
3
3
 
4
4
  K = TypeVar('K')
5
5
  V = TypeVar('V')
@@ -12,7 +12,7 @@ class Database(ABC, Generic[K, V]):
12
12
  DEFAULT = None
13
13
 
14
14
  def __init__(self) -> None:
15
- self._subscribers: set[Database] = set()
15
+ self._subscribers: Set[Database] = set()
16
16
 
17
17
  def _register_subscriber(self, subscriber: 'Database') -> None:
18
18
  self._subscribers.add(subscriber)
@@ -1,11 +1,11 @@
1
1
  from threading import Thread
2
2
  from abc import ABC, abstractmethod
3
- from typing import Optional, Any,Tuple as t_tuple
3
+ from typing import Optional, Any,Tuple as Tuple
4
4
  from logging import error
5
5
  import danielutils # this is explicitly this way to prevent circular import
6
6
  from ...reflection import get_python_version
7
7
  if get_python_version() >= (3, 9):
8
- from builtins import tuple as t_tuple # type:ignore
8
+ from builtins import tuple as Tuple # type:ignore
9
9
 
10
10
 
11
11
  class Worker(ABC):
@@ -59,7 +59,7 @@ class Worker(ABC):
59
59
  """
60
60
  self.pool._notify_subscribers() # pylint: disable=protected-access
61
61
 
62
- def acquire(self) -> Optional[t_tuple[Any]]:
62
+ def acquire(self) -> Optional[Tuple[Any]]:
63
63
  """acquire a new job object to work on from the pool
64
64
  will return a tuple of only one object (the job) or None if there are no more jobs
65
65
  Returns:
@@ -1,11 +1,11 @@
1
1
  from queue import Queue
2
- from typing import Optional, Any, Type as t_type, Tuple as t_tuple, List as t_list
2
+ from typing import Optional, Any, Type as t_type, Tuple as Tuple, List as List
3
3
  from threading import Semaphore
4
4
  from .worker import Worker
5
5
  from ...reflection import get_python_version
6
6
 
7
7
  if get_python_version() >= (3, 9):
8
- from builtins import type as t_type, tuple as t_tuple, list as t_list # type:ignore
8
+ from builtins import type as t_type, tuple as Tuple, list as List # type:ignore
9
9
 
10
10
 
11
11
  class WorkerPool:
@@ -15,9 +15,9 @@ class WorkerPool:
15
15
  def __init__(self, num_workers: int, worker_class: t_type[Worker], w_kwargs: dict, global_variables: dict) -> None:
16
16
  self.num_workers = num_workers
17
17
  self.global_variables: dict = global_variables
18
- self.q: Queue[t_tuple[Any]] = Queue()
18
+ self.q: Queue[Tuple[Any]] = Queue()
19
19
  self.worker_class = worker_class
20
- self.workers: t_list[Worker] = []
20
+ self.workers: List[Worker] = []
21
21
  self.sem = Semaphore(0)
22
22
  self.w_kwargs = w_kwargs
23
23
 
@@ -34,7 +34,7 @@ class WorkerPool:
34
34
  self.q.put((job,))
35
35
  self.sem.release()
36
36
 
37
- def _acquire(self) -> Optional[t_tuple[Any]]:
37
+ def _acquire(self) -> Optional[Tuple[Any]]:
38
38
  """acquire a new job from the pool
39
39
 
40
40
  Returns:
@@ -1,9 +1,9 @@
1
1
  import copy, re
2
- from typing import Any, Callable, Union, Tuple as t_tuple, List as t_list, Dict as t_dict
2
+ from typing import Any, Callable, Union, Tuple as Tuple, List as List, Dict as Dict
3
3
  from ..reflection import get_python_version # pylint :disable=relative-beyond-top-level
4
4
 
5
5
  if get_python_version() >= (3, 9):
6
- from builtins import tuple as t_tuple, list as t_list, dict as t_dict # type:ignore
6
+ from builtins import tuple as Tuple, list as List, dict as Dict # type:ignore
7
7
 
8
8
 
9
9
  class Argument:
@@ -20,7 +20,7 @@ class Command:
20
20
  """
21
21
 
22
22
  def __init__(self, command: Union[Argument, str], callback: Callable,
23
- explanation: str = "", *, options: t_tuple[Argument, ...] = tuple()) -> None:
23
+ explanation: str = "", *, options: Tuple[Argument, ...] = tuple()) -> None:
24
24
  self.command = command if isinstance(
25
25
  command, Argument) else Argument(command)
26
26
  self.callback = callback
@@ -41,10 +41,10 @@ class REPL:
41
41
  """
42
42
 
43
43
  # pylint: disable=dangerous-default-value
44
- def __init__(self, routes: t_list[Command], *, prompt_symbol: str = ">>> ", exit_keywords: set = {"exit", "quit"}):
44
+ def __init__(self, routes: List[Command], *, prompt_symbol: str = ">>> ", exit_keywords: set = {"exit", "quit"}):
45
45
  self.prompt_symbol = prompt_symbol
46
46
  self.exit_keywords = copy.copy(exit_keywords)
47
- self.routes: t_dict[str, Command] = {
47
+ self.routes: Dict[str, Command] = {
48
48
  com.command.name: com for com in routes}
49
49
 
50
50
  def run(self) -> None:
@@ -1,17 +1,17 @@
1
1
  import types
2
2
  from abc import abstractmethod
3
- from typing import Any, Iterable, List as t_list, Set as t_set, Dict as t_dict, Tuple as t_tuple
3
+ from typing import Any, Iterable, List as List, Set as Set, Dict as Dict, Tuple as Tuple
4
4
  from ...functions import types_subseteq, isoftype
5
5
  from ...reflection import get_caller_name, get_python_version
6
6
 
7
7
  if get_python_version() >= (3, 9):
8
- from builtins import list as t_list, set as t_set, dict as t_dict, tuple as t_tuple # type:ignore
8
+ from builtins import list as List, set as Set, dict as Dict, tuple as Tuple # type:ignore
9
9
  # needed for python 3.8
10
10
  class_to_type = {
11
- list: t_list,
12
- set: t_set,
13
- dict: t_dict,
14
- t_tuple: t_tuple,
11
+ list: List,
12
+ set: Set,
13
+ dict: Dict,
14
+ Tuple: Tuple,
15
15
  }
16
16
 
17
17
 
@@ -7,7 +7,7 @@ from .factory import create_typed_class
7
7
  T = TypeVar("T", bound=Any)
8
8
 
9
9
 
10
- # class ptlist(t_list[T], Generic[T]):
10
+ # class ptlist(List[T], Generic[T]):
11
11
  # """like 'list' but with runtime type safety
12
12
  # """
13
13
 
@@ -18,7 +18,7 @@ T = TypeVar("T", bound=Any)
18
18
  # def __instancecheck__(self, instance: Any) -> bool:
19
19
  # if isinstance(instance, ptlist):
20
20
  # return types_subseteq(instance._params, self._params)
21
- # return isoftype(instance, t_list[self._params]) # type: ignore
21
+ # return isoftype(instance, List[self._params]) # type: ignore
22
22
 
23
23
  # def __init__(self, item) -> None:
24
24
  # if not get_caller_name(0) == "__class_getitem__":
@@ -17,7 +17,7 @@ class ColoredText:
17
17
  """
18
18
 
19
19
  @staticmethod # type:ignore
20
- @validate
20
+ @validate # type:ignore
21
21
  def from_rgb(red: int, green: int, blue: int, text: str) -> str:
22
22
  """Applies an RGB color to the given text.
23
23
 
@@ -1,7 +1,7 @@
1
1
  from ..decorators import validate
2
2
 
3
3
 
4
- @validate
4
+ @validate # type:ignore
5
5
  def char_to_int(c: str) -> int:
6
6
  """convert char to its representing int value
7
7
 
@@ -14,7 +14,7 @@ def char_to_int(c: str) -> int:
14
14
  return ord(c)
15
15
 
16
16
 
17
- @validate
17
+ @validate # type:ignore
18
18
  def int_to_char(num: int) -> str:
19
19
  """convert int to its corresponding char
20
20
 
@@ -27,7 +27,7 @@ def int_to_char(num: int) -> str:
27
27
  return chr(num)
28
28
 
29
29
 
30
- @validate
30
+ @validate # type:ignore
31
31
  def hex_to_char(h: str) -> str:
32
32
  """convert hex number to char
33
33
 
@@ -40,7 +40,7 @@ def hex_to_char(h: str) -> str:
40
40
  return int_to_char(hex_to_dec(h))
41
41
 
42
42
 
43
- @validate
43
+ @validate # type:ignore
44
44
  def hex_to_dec(h: str) -> int:
45
45
  """convert hex to dec
46
46
 
@@ -53,7 +53,7 @@ def hex_to_dec(h: str) -> int:
53
53
  return int(h, 16)
54
54
 
55
55
 
56
- @validate
56
+ @validate # type:ignore
57
57
  def char_to_hex(c: str) -> str:
58
58
  """convert char to hex
59
59
 
@@ -66,7 +66,7 @@ def char_to_hex(c: str) -> str:
66
66
  return int_to_hex(char_to_int(c))
67
67
 
68
68
 
69
- @validate
69
+ @validate # type:ignore
70
70
  def dec_to_hex(num: int) -> str:
71
71
  """convert decimal number to hex
72
72
 
@@ -79,7 +79,7 @@ def dec_to_hex(num: int) -> str:
79
79
  return int_to_hex(num)
80
80
 
81
81
 
82
- @validate
82
+ @validate # type:ignore
83
83
  def int_to_hex(num: int) -> str:
84
84
  """converts an int to it's hex representation
85
85
 
@@ -92,7 +92,7 @@ def int_to_hex(num: int) -> str:
92
92
  return hex(num)
93
93
 
94
94
 
95
- @validate
95
+ @validate # type:ignore
96
96
  def bytes_to_str(b: bytes) -> str:
97
97
  """decodes bytes to str
98
98
 
@@ -105,7 +105,7 @@ def bytes_to_str(b: bytes) -> str:
105
105
  return b.decode("utf-8")
106
106
 
107
107
 
108
- @validate
108
+ @validate # type:ignore
109
109
  def str_to_bytes(s: str) -> bytes:
110
110
  """encodes a string to bytes
111
111
 
@@ -1,12 +1,12 @@
1
1
  """functions that convert values to int"""
2
- from typing import Union, List as t_list
2
+ from typing import Union, List as List
3
3
  from ..main_conversions import char_to_int
4
4
  from ...reflection import get_python_version
5
5
  if get_python_version() >= (3, 9):
6
- from builtins import list as t_list
6
+ from builtins import list as List
7
7
 
8
8
 
9
- def to_int(value: str) -> Union[int, t_list[int]]:
9
+ def to_int(value: str) -> Union[int, List[int]]:
10
10
  """converts a single character or a full string to an int or list of int respectively
11
11
  """
12
12
  if len(value) == 1:
@@ -1,11 +1,11 @@
1
- from typing import Optional, Generator, List as t_list, Set as t_set, Dict as t_dict, Generic, \
1
+ from typing import Optional, Generator, List as List, Set as Set, Dict as Dict, Generic, \
2
2
  TypeVar, Iterable, Iterator
3
3
  from ..queue import Queue
4
4
  from .multinode import MultiNode
5
5
  from ...reflection import get_python_version
6
6
 
7
7
  if get_python_version() >= (3, 9):
8
- from builtins import list as t_list, set as t_set, dict as t_dict
8
+ from builtins import list as List, set as Set, dict as Dict
9
9
 
10
10
  T = TypeVar("T")
11
11
 
@@ -16,11 +16,11 @@ class Graph(Generic[T]):
16
16
  This class represents a directed graph, where nodes can be connected through edges.
17
17
 
18
18
  Attributes:
19
- nodes (Optional[t_list[MultiNode]]): A list of MultiNode instances representing the nodes in the graph.
19
+ nodes (Optional[List[MultiNode]]): A list of MultiNode instances representing the nodes in the graph.
20
20
  Default is an empty list.
21
21
 
22
22
  Methods:
23
- __init__(self, nodes: Optional[t_list[MultiNode]] = None): Initialize the Graph with given nodes.
23
+ __init__(self, nodes: Optional[List[MultiNode]] = None): Initialize the Graph with given nodes.
24
24
  add_node(self, node): Add a node to the graph.
25
25
  _extended_dfs(self) -> Generator: Perform an extended depth-first search on the graph.
26
26
  dfs(self) -> Generator: Perform a depth-first search on the graph.
@@ -30,13 +30,13 @@ class Graph(Generic[T]):
30
30
 
31
31
  """
32
32
 
33
- def to_dict(self) -> t_dict[T, t_set[T]]:
33
+ def to_dict(self) -> Dict[T, Set[T]]:
34
34
  """
35
35
  converts the graph to a dictionary.
36
36
  Returns:
37
37
  dict: A dictionary representing the graph.
38
38
  """
39
- dct: t_dict[T, t_set[T]] = {}
39
+ dct: Dict[T, Set[T]] = {}
40
40
  for node in self:
41
41
  v = dct.get(node.data, set())
42
42
  for child in node:
@@ -45,7 +45,7 @@ class Graph(Generic[T]):
45
45
  return dct
46
46
 
47
47
  @staticmethod
48
- def from_dict(dct: t_dict[T, Iterable[T]]) -> "Graph[T]":
48
+ def from_dict(dct: Dict[T, Iterable[T]]) -> "Graph[T]":
49
49
  """
50
50
  converts a dictionary to a graph.
51
51
  Args:
@@ -55,7 +55,7 @@ class Graph(Generic[T]):
55
55
  Graph[T]: A graph representing the given dictionary.
56
56
  """
57
57
  g: Graph[T] = Graph()
58
- seen: t_dict[T, MultiNode[T]] = {}
58
+ seen: Dict[T, MultiNode[T]] = {}
59
59
  for k, v in dct.items():
60
60
  seen[k] = seen.get(k, MultiNode(k))
61
61
 
@@ -66,8 +66,8 @@ class Graph(Generic[T]):
66
66
  g.add_node(seen[k])
67
67
  return g
68
68
 
69
- def __init__(self, nodes: Optional[t_list[MultiNode[T]]] = None):
70
- self.nodes: t_list[MultiNode[T]] = nodes if nodes is not None else []
69
+ def __init__(self, nodes: Optional[List[MultiNode[T]]] = None):
70
+ self.nodes: List[MultiNode[T]] = nodes if nodes is not None else []
71
71
 
72
72
  def add_node(self, node: MultiNode[T]) -> None:
73
73
  """Add a node to the graph.
@@ -77,7 +77,7 @@ class Graph(Generic[T]):
77
77
  """
78
78
  self.nodes.append(node)
79
79
 
80
- def _extended_dfs(self) -> Generator[MultiNode[T], None, t_list[MultiNode[T]]]:
80
+ def _extended_dfs(self) -> Generator[MultiNode[T], None, List[MultiNode[T]]]:
81
81
  """Perform an extended depth-first search on the graph.
82
82
 
83
83
  This private method performs an extended depth-first search (DFS) on the graph,
@@ -91,7 +91,7 @@ class Graph(Generic[T]):
91
91
  enter_times: dict = {}
92
92
  exit_times: dict = {}
93
93
  travel_index: int = 1
94
- all_nodes: t_list[MultiNode] = []
94
+ all_nodes: List[MultiNode] = []
95
95
 
96
96
  def handle_node(node: MultiNode[T]) -> Generator[MultiNode[T], None, None]:
97
97
  nonlocal travel_index
@@ -143,7 +143,7 @@ class Graph(Generic[T]):
143
143
  """
144
144
  yield from self._extended_dfs()
145
145
 
146
- def topological_sort(self) -> t_list[MultiNode[T]]:
146
+ def topological_sort(self) -> List[MultiNode[T]]:
147
147
  """Get a topological sort of the graph nodes.
148
148
 
149
149
  This method performs a topological sort on the graph using the private _extended_dfs method.
@@ -169,7 +169,7 @@ class Graph(Generic[T]):
169
169
  q: Queue[MultiNode[T]] = Queue()
170
170
  for node in self.nodes:
171
171
  q.push(node)
172
- seen: t_set[MultiNode] = set()
172
+ seen: Set[MultiNode] = set()
173
173
  for node in q:
174
174
  if node not in seen:
175
175
  seen.add(node)
@@ -1,9 +1,9 @@
1
- from typing import Optional, Generator, TypeVar, Generic, List as t_list
1
+ from typing import Optional, Generator, TypeVar, Generic, List as List
2
2
 
3
3
  from ...reflection import get_python_version
4
4
 
5
5
  if get_python_version() >= (3, 9):
6
- from builtins import list as t_list
6
+ from builtins import list as List
7
7
  T = TypeVar("T")
8
8
 
9
9
 
@@ -11,9 +11,9 @@ class MultiNode(Generic[T]):
11
11
  """A node class with no limit to children amount
12
12
  """
13
13
 
14
- def __init__(self, data: T, children: Optional[t_list[Optional['MultiNode[T]']]] = None):
14
+ def __init__(self, data: T, children: Optional[List[Optional['MultiNode[T]']]] = None):
15
15
  self.data: T = data
16
- self._children: t_list[Optional[MultiNode[T]]] = children if children is not None else []
16
+ self._children: List[Optional[MultiNode[T]]] = children if children is not None else []
17
17
 
18
18
  def __getitem__(self, index) -> T:
19
19
  return self._children[index]
@@ -1,8 +1,8 @@
1
- from typing import Generic, TypeVar, Iterator, List as t_list
1
+ from typing import Generic, TypeVar, Iterator, List as List
2
2
  from ...reflection import get_python_version
3
3
 
4
4
  if get_python_version() >= (3, 9):
5
- from builtins import list as t_list
5
+ from builtins import list as List
6
6
  T = TypeVar("T")
7
7
 
8
8
 
@@ -57,7 +57,7 @@ class Queue(Generic[T]):
57
57
  def __iter__(self) -> Iterator[T]:
58
58
  return iter(self.data)
59
59
 
60
- def push_many(self, arr: t_list[T]):
60
+ def push_many(self, arr: List[T]):
61
61
  """will push many objects to the Queue
62
62
 
63
63
  Args:
@@ -1,9 +1,9 @@
1
- from typing import Union, Any, Callable,Dict as t_dict
1
+ from typing import Union, Any, Callable,Dict as Dict
2
2
  from .binary_tree import BinaryTree
3
3
  from ..graph import BinaryNode
4
4
  from ...reflection import get_python_version
5
5
  if get_python_version()>=(3,9):
6
- from builtins import dict as t_dict
6
+ from builtins import dict as Dict
7
7
 
8
8
  class BinarySyntaxTree(BinaryTree):
9
9
  """
@@ -11,7 +11,7 @@ class BinarySyntaxTree(BinaryTree):
11
11
  """
12
12
 
13
13
  @staticmethod
14
- def _evaluate_node(v: BinaryNode, operator_func_dict: t_dict[Any, Callable[[Any, Any], Any]]):
14
+ def _evaluate_node(v: BinaryNode, operator_func_dict: Dict[Any, Callable[[Any, Any], Any]]):
15
15
  if not isinstance(v, BinaryNode) or v.left is None and v.right is None:
16
16
  return v
17
17
 
@@ -74,7 +74,7 @@ class BinarySyntaxTree(BinaryTree):
74
74
  def __reversed__(self) -> "BinarySyntaxTree":
75
75
  return self.reverse()
76
76
 
77
- def evaluate(self, operator_func_dict: t_dict[Any, Callable[[Any, Any], Any]]) -> Any:
77
+ def evaluate(self, operator_func_dict: Dict[Any, Callable[[Any, Any], Any]]) -> Any:
78
78
  return BinarySyntaxTree._evaluate_node(self.root, operator_func_dict)
79
79
 
80
80
 
@@ -2,7 +2,7 @@ import json
2
2
  from .decorators import validate
3
3
 
4
4
 
5
- @validate
5
+ @validate # type:ignore # type:ignore
6
6
  def dict_to_json(dct: dict) -> str:
7
7
  """converts a python dict to a json object
8
8
 
@@ -15,7 +15,7 @@ def dict_to_json(dct: dict) -> str:
15
15
  return json.dumps(dct, indent=4)
16
16
 
17
17
 
18
- @validate
18
+ @validate # type:ignore
19
19
  def json_to_dict(json_str: str) -> dict:
20
20
  """converts a json object from a string to a python dict
21
21
 
@@ -10,7 +10,7 @@ P = ParamSpec("P")
10
10
  FuncT = Callable[P, T] # type:ignore
11
11
 
12
12
 
13
- @validate
13
+ @validate # type:ignore
14
14
  def atomic(func: FuncT) -> FuncT:
15
15
  """will make function thread safe by making it
16
16
  accessible for only one thread at one time
@@ -8,7 +8,7 @@ P = ParamSpec("P")
8
8
  FuncT = Callable[P, T] # type:ignore
9
9
 
10
10
 
11
- @validate(strict=False)
11
+ @validate # type:ignore(strict=False)
12
12
  def attach(before: Optional[Callable] = None, after: Optional[Callable] = None) -> Callable[[FuncT], FuncT]:
13
13
  """attaching functions to a function
14
14
 
@@ -3,7 +3,7 @@ from typing import Callable, Optional, Union
3
3
  from .validate import validate
4
4
 
5
5
 
6
- @validate(strict=False)
6
+ @validate # type:ignore(strict=False)
7
7
  def decorate_conditionally(decorator: Callable, predicate: Union[bool, Callable[[], bool]], *,
8
8
  decorator_args: Optional[list] = None, decorator_kwargs: Optional[dict] = None):
9
9
  """will decorate a function iff the predicate is True or returns True
@@ -11,7 +11,7 @@ P = ParamSpec("P")
11
11
  FuncT = Callable[P, T] # type:ignore
12
12
 
13
13
 
14
- @validate
14
+ @validate # type:ignore
15
15
  def limit_recursion(max_depth: int, return_value: Any = None, quiet: bool = True) -> Callable[[FuncT], FuncT]:
16
16
  """decorator to limit recursion of functions
17
17
 
@@ -1,22 +1,22 @@
1
1
  import functools
2
- from typing import Callable, Any, TypeVar, Dict as t_dict
2
+ from typing import Callable, Any, TypeVar, Dict
3
3
  from copy import deepcopy
4
4
  from .validate import validate
5
- from ..versioned_imports import ParamSpec, t_dict
5
+ from ..versioned_imports import ParamSpec
6
6
 
7
7
  T = TypeVar("T")
8
8
  P = ParamSpec("P")
9
9
  FuncT = Callable[P, T] # type:ignore
10
10
 
11
11
 
12
- @validate
12
+ @validate # type:ignore
13
13
  def memo(func: FuncT) -> FuncT:
14
14
  """decorator to memorize function calls in order to improve performance by using more memory
15
15
 
16
16
  Args:
17
17
  func (Callable): function to memorize
18
18
  """
19
- cache: t_dict[tuple, Any] = {}
19
+ cache: Dict[tuple, Any] = {}
20
20
 
21
21
  @functools.wraps(func)
22
22
  def wrapper(*args, **kwargs):
@@ -1,11 +1,11 @@
1
- from typing import Callable, cast, Any, TypeVar, Dict as t_dict, List as t_list
1
+ from typing import Callable, cast, Any, TypeVar, Dict
2
2
  import inspect
3
3
  import functools
4
4
  from ..reflection import is_function_annotated_properly
5
5
  from ..functions import isoftype, isoneof, isoneof_strict
6
6
  from ..exceptions import OverloadDuplication, OverloadNotFound
7
7
  from .deprecate import deprecate
8
- from ..versioned_imports import ParamSpec, t_dict, t_list
8
+ from ..versioned_imports import ParamSpec
9
9
 
10
10
  T = TypeVar("T")
11
11
  P = ParamSpec("P")
@@ -14,7 +14,7 @@ T2 = TypeVar("T2")
14
14
  P2 = ParamSpec("P2")
15
15
  FuncT2 = Callable[P2, T2] # type:ignore
16
16
 
17
- __overload_dict: t_dict[str, t_dict[tuple, Callable]] = {}
17
+ __overload_dict: Dict[str, Dict[tuple, Callable]] = {}
18
18
 
19
19
 
20
20
  @deprecate("'explicit_global_overload' is a legacy decorator please use 'overload' instead")
@@ -122,7 +122,7 @@ class overload:
122
122
  overload._validate(func)
123
123
  self._qualname = func.__qualname__
124
124
  self._moudle = func.__module__
125
- self._functions: t_dict[int, t_list[Callable]] = {}
125
+ self._functions: Dict[int, Dict[Callable]] = {}
126
126
  self._functions[overload._get_key(func)] = [func]
127
127
  functools.wraps(func)(self)
128
128
 
@@ -9,7 +9,7 @@ P = ParamSpec("P")
9
9
  FuncT = Callable[P, T] # type:ignore
10
10
 
11
11
 
12
- @validate
12
+ @validate # type:ignore
13
13
  def PartiallyImplemented(func: FuncT) -> FuncT:
14
14
  """decorator to mark function as not fully implemented for development purposes
15
15
 
@@ -9,7 +9,7 @@ P = ParamSpec("P")
9
9
  FuncT = Callable[P, T] # type:ignore
10
10
 
11
11
 
12
- @validate
12
+ @validate # type:ignore
13
13
  def timeout(duration: Union[int, float], silent: bool = False) -> Callable[[FuncT], FuncT]:
14
14
  """A decorator to limit runtime for a function
15
15
 
@@ -1,4 +1,4 @@
1
- from typing import Callable, Union, Any
1
+ from typing import Callable, Any, Dict, List
2
2
 
3
3
 
4
4
  def is_default_implementation(func: Callable) -> bool:
@@ -10,7 +10,7 @@ def usable(func: Callable) -> bool:
10
10
 
11
11
 
12
12
  def total_ordering(cls: type) -> type:
13
- funcs: dict[str, Callable[[Any, Any], Any]] = {
13
+ funcs: Dict[str, Callable[[Any, Any], Any]] = {
14
14
  '__eq__': getattr(cls, '__eq__'),
15
15
  '__ne__': getattr(cls, '__ne__'),
16
16
  '__gt__': getattr(cls, '__gt__'),
@@ -18,11 +18,11 @@ def total_ordering(cls: type) -> type:
18
18
  '__lt__': getattr(cls, '__lt__'),
19
19
  '__le__': getattr(cls, '__le__'),
20
20
  }
21
- g1: list[Callable[[Any, Any], Any]] = [funcs["__eq__"], funcs["__ne__"]]
21
+ g1: List[Callable[[Any, Any], Any]] = [funcs["__eq__"], funcs["__ne__"]]
22
22
  u1 = any(map(usable, g1))
23
- g2: list[Callable[[Any, Any], Any]] = [funcs["__ge__"], funcs["__gt__"]]
23
+ g2: List[Callable[[Any, Any], Any]] = [funcs["__ge__"], funcs["__gt__"]]
24
24
  u2 = any(map(usable, g2))
25
- g3: list[Callable[[Any, Any], Any]] = [funcs["__lt__"], funcs["__le__"]]
25
+ g3: List[Callable[[Any, Any], Any]] = [funcs["__lt__"], funcs["__le__"]]
26
26
  u3 = any(map(usable, g3))
27
27
  if sum(map(int, [u1, u2, u3])) < 2:
28
28
  raise ValueError("There are not enough functions from different groups implemented")
@@ -199,7 +199,7 @@ def validate(strict: Union[FuncT, bool] = True) -> FuncT:
199
199
  # return result
200
200
  # return wrapper
201
201
 
202
- # @validate
202
+ # @validate # type:ignore
203
203
  # def NotImplemented(func: Callable) -> Callable:
204
204
  # """decorator to mark function as not implemented for development purposes
205
205