@scrypted/server 0.0.141 → 0.0.142

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.

Potentially problematic release.


This version of @scrypted/server might be problematic. Click here for more details.

Files changed (710) hide show
  1. package/package.json +1 -1
  2. package/.venv/bin/Activate.ps1 +0 -241
  3. package/.venv/bin/activate +0 -66
  4. package/.venv/bin/activate.csh +0 -25
  5. package/.venv/bin/activate.fish +0 -64
  6. package/.venv/bin/pip +0 -8
  7. package/.venv/bin/pip3 +0 -8
  8. package/.venv/bin/pip3.9 +0 -8
  9. package/.venv/lib/python3.9/site-packages/_distutils_hack/__init__.py +0 -198
  10. package/.venv/lib/python3.9/site-packages/_distutils_hack/override.py +0 -1
  11. package/.venv/lib/python3.9/site-packages/distutils-precedence.pth +0 -1
  12. package/.venv/lib/python3.9/site-packages/pgi/__init__.py +0 -62
  13. package/.venv/lib/python3.9/site-packages/pgi/_compat.py +0 -74
  14. package/.venv/lib/python3.9/site-packages/pgi/callback.py +0 -15
  15. package/.venv/lib/python3.9/site-packages/pgi/cffilib/__init__.py +0 -12
  16. package/.venv/lib/python3.9/site-packages/pgi/cffilib/_compat.py +0 -25
  17. package/.venv/lib/python3.9/site-packages/pgi/cffilib/_utils.py +0 -119
  18. package/.venv/lib/python3.9/site-packages/pgi/cffilib/gir/__init__.py +0 -60
  19. package/.venv/lib/python3.9/site-packages/pgi/cffilib/gir/_cdef.py +0 -574
  20. package/.venv/lib/python3.9/site-packages/pgi/cffilib/gir/_ffi.py +0 -25
  21. package/.venv/lib/python3.9/site-packages/pgi/cffilib/gir/error.py +0 -13
  22. package/.venv/lib/python3.9/site-packages/pgi/cffilib/gir/giarginfo.py +0 -73
  23. package/.venv/lib/python3.9/site-packages/pgi/cffilib/gir/giargument.py +0 -36
  24. package/.venv/lib/python3.9/site-packages/pgi/cffilib/gir/gibaseinfo.py +0 -113
  25. package/.venv/lib/python3.9/site-packages/pgi/cffilib/gir/gicallableinfo.py +0 -75
  26. package/.venv/lib/python3.9/site-packages/pgi/cffilib/gir/giconstantinfo.py +0 -22
  27. package/.venv/lib/python3.9/site-packages/pgi/cffilib/gir/gienuminfo.py +0 -59
  28. package/.venv/lib/python3.9/site-packages/pgi/cffilib/gir/gifieldinfo.py +0 -40
  29. package/.venv/lib/python3.9/site-packages/pgi/cffilib/gir/gifunctioninfo.py +0 -64
  30. package/.venv/lib/python3.9/site-packages/pgi/cffilib/gir/giinterfaceinfo.py +0 -93
  31. package/.venv/lib/python3.9/site-packages/pgi/cffilib/gir/giobjectinfo.py +0 -143
  32. package/.venv/lib/python3.9/site-packages/pgi/cffilib/gir/gipropertyinfo.py +0 -28
  33. package/.venv/lib/python3.9/site-packages/pgi/cffilib/gir/giregisteredtypeinfo.py +0 -27
  34. package/.venv/lib/python3.9/site-packages/pgi/cffilib/gir/girepository.py +0 -143
  35. package/.venv/lib/python3.9/site-packages/pgi/cffilib/gir/gisignalinfo.py +0 -55
  36. package/.venv/lib/python3.9/site-packages/pgi/cffilib/gir/gistructinfo.py +0 -55
  37. package/.venv/lib/python3.9/site-packages/pgi/cffilib/gir/gitypeinfo.py +0 -66
  38. package/.venv/lib/python3.9/site-packages/pgi/cffilib/gir/gitypelib.py +0 -40
  39. package/.venv/lib/python3.9/site-packages/pgi/cffilib/gir/giunioninfo.py +0 -66
  40. package/.venv/lib/python3.9/site-packages/pgi/cffilib/glib/__init__.py +0 -8
  41. package/.venv/lib/python3.9/site-packages/pgi/cffilib/glib/_cdef.py +0 -101
  42. package/.venv/lib/python3.9/site-packages/pgi/cffilib/glib/glib.py +0 -260
  43. package/.venv/lib/python3.9/site-packages/pgi/cffilib/gobject/__init__.py +0 -15
  44. package/.venv/lib/python3.9/site-packages/pgi/cffilib/gobject/_cdef.py +0 -45
  45. package/.venv/lib/python3.9/site-packages/pgi/cffilib/gobject/_ffi.py +0 -26
  46. package/.venv/lib/python3.9/site-packages/pgi/cffilib/gobject/gobject.py +0 -27
  47. package/.venv/lib/python3.9/site-packages/pgi/clib/__init__.py +0 -11
  48. package/.venv/lib/python3.9/site-packages/pgi/clib/_compat.py +0 -20
  49. package/.venv/lib/python3.9/site-packages/pgi/clib/_utils.py +0 -213
  50. package/.venv/lib/python3.9/site-packages/pgi/clib/gir/__init__.py +0 -71
  51. package/.venv/lib/python3.9/site-packages/pgi/clib/gir/error.py +0 -13
  52. package/.venv/lib/python3.9/site-packages/pgi/clib/gir/giarginfo.py +0 -65
  53. package/.venv/lib/python3.9/site-packages/pgi/clib/gir/giargument.py +0 -58
  54. package/.venv/lib/python3.9/site-packages/pgi/clib/gir/gibaseinfo.py +0 -152
  55. package/.venv/lib/python3.9/site-packages/pgi/clib/gir/gicallableinfo.py +0 -203
  56. package/.venv/lib/python3.9/site-packages/pgi/clib/gir/giconstantinfo.py +0 -35
  57. package/.venv/lib/python3.9/site-packages/pgi/clib/gir/gienuminfo.py +0 -64
  58. package/.venv/lib/python3.9/site-packages/pgi/clib/gir/gifieldinfo.py +0 -46
  59. package/.venv/lib/python3.9/site-packages/pgi/clib/gir/giinterfaceinfo.py +0 -83
  60. package/.venv/lib/python3.9/site-packages/pgi/clib/gir/giobjectinfo.py +0 -134
  61. package/.venv/lib/python3.9/site-packages/pgi/clib/gir/gipropertyinfo.py +0 -36
  62. package/.venv/lib/python3.9/site-packages/pgi/clib/gir/giregisteredtypeinfo.py +0 -34
  63. package/.venv/lib/python3.9/site-packages/pgi/clib/gir/girepository.py +0 -200
  64. package/.venv/lib/python3.9/site-packages/pgi/clib/gir/gistructinfo.py +0 -55
  65. package/.venv/lib/python3.9/site-packages/pgi/clib/gir/gitypeinfo.py +0 -97
  66. package/.venv/lib/python3.9/site-packages/pgi/clib/gir/gitypelib.py +0 -56
  67. package/.venv/lib/python3.9/site-packages/pgi/clib/gir/giunioninfo.py +0 -60
  68. package/.venv/lib/python3.9/site-packages/pgi/clib/glib.py +0 -336
  69. package/.venv/lib/python3.9/site-packages/pgi/clib/gobject.py +0 -405
  70. package/.venv/lib/python3.9/site-packages/pgi/codegen/__init__.py +0 -28
  71. package/.venv/lib/python3.9/site-packages/pgi/codegen/arguments.py +0 -640
  72. package/.venv/lib/python3.9/site-packages/pgi/codegen/backend.py +0 -95
  73. package/.venv/lib/python3.9/site-packages/pgi/codegen/cbargs.py +0 -152
  74. package/.venv/lib/python3.9/site-packages/pgi/codegen/cbreturn.py +0 -77
  75. package/.venv/lib/python3.9/site-packages/pgi/codegen/cffi_backend.py +0 -424
  76. package/.venv/lib/python3.9/site-packages/pgi/codegen/construct.py +0 -222
  77. package/.venv/lib/python3.9/site-packages/pgi/codegen/ctypes_backend/__init__.py +0 -11
  78. package/.venv/lib/python3.9/site-packages/pgi/codegen/ctypes_backend/main.py +0 -184
  79. package/.venv/lib/python3.9/site-packages/pgi/codegen/ctypes_backend/types_basic.py +0 -705
  80. package/.venv/lib/python3.9/site-packages/pgi/codegen/ctypes_backend/types_container.py +0 -236
  81. package/.venv/lib/python3.9/site-packages/pgi/codegen/ctypes_backend/types_interface.py +0 -402
  82. package/.venv/lib/python3.9/site-packages/pgi/codegen/ctypes_backend/types_other.py +0 -93
  83. package/.venv/lib/python3.9/site-packages/pgi/codegen/ctypes_backend/utils.py +0 -168
  84. package/.venv/lib/python3.9/site-packages/pgi/codegen/fieldgen.py +0 -114
  85. package/.venv/lib/python3.9/site-packages/pgi/codegen/fields.py +0 -244
  86. package/.venv/lib/python3.9/site-packages/pgi/codegen/funcgen.py +0 -376
  87. package/.venv/lib/python3.9/site-packages/pgi/codegen/null_backend.py +0 -110
  88. package/.venv/lib/python3.9/site-packages/pgi/codegen/returnvalues.py +0 -443
  89. package/.venv/lib/python3.9/site-packages/pgi/codegen/siggen.py +0 -157
  90. package/.venv/lib/python3.9/site-packages/pgi/codegen/utils.py +0 -248
  91. package/.venv/lib/python3.9/site-packages/pgi/const.py +0 -9
  92. package/.venv/lib/python3.9/site-packages/pgi/constant.py +0 -32
  93. package/.venv/lib/python3.9/site-packages/pgi/debug.py +0 -31
  94. package/.venv/lib/python3.9/site-packages/pgi/enum.py +0 -244
  95. package/.venv/lib/python3.9/site-packages/pgi/field.py +0 -58
  96. package/.venv/lib/python3.9/site-packages/pgi/finalizer.py +0 -3
  97. package/.venv/lib/python3.9/site-packages/pgi/foreign/__init__.py +0 -71
  98. package/.venv/lib/python3.9/site-packages/pgi/foreign/_base.py +0 -43
  99. package/.venv/lib/python3.9/site-packages/pgi/foreign/cairo.py +0 -41
  100. package/.venv/lib/python3.9/site-packages/pgi/function.py +0 -12
  101. package/.venv/lib/python3.9/site-packages/pgi/gerror.py +0 -58
  102. package/.venv/lib/python3.9/site-packages/pgi/gtype.py +0 -168
  103. package/.venv/lib/python3.9/site-packages/pgi/importer.py +0 -189
  104. package/.venv/lib/python3.9/site-packages/pgi/module.py +0 -141
  105. package/.venv/lib/python3.9/site-packages/pgi/obj.py +0 -519
  106. package/.venv/lib/python3.9/site-packages/pgi/overrides/GLib.py +0 -1013
  107. package/.venv/lib/python3.9/site-packages/pgi/overrides/GObject.py +0 -583
  108. package/.venv/lib/python3.9/site-packages/pgi/overrides/Gdk.py +0 -454
  109. package/.venv/lib/python3.9/site-packages/pgi/overrides/Gio.py +0 -237
  110. package/.venv/lib/python3.9/site-packages/pgi/overrides/Gtk.py +0 -2412
  111. package/.venv/lib/python3.9/site-packages/pgi/overrides/Pango.py +0 -53
  112. package/.venv/lib/python3.9/site-packages/pgi/overrides/Poppler.py +0 -61
  113. package/.venv/lib/python3.9/site-packages/pgi/overrides/__init__.py +0 -327
  114. package/.venv/lib/python3.9/site-packages/pgi/overrides/keysyms.py +0 -54
  115. package/.venv/lib/python3.9/site-packages/pgi/properties.py +0 -313
  116. package/.venv/lib/python3.9/site-packages/pgi/propertyhelper.py +0 -12
  117. package/.venv/lib/python3.9/site-packages/pgi/repository/__init__.py +0 -10
  118. package/.venv/lib/python3.9/site-packages/pgi/signalhelper.py +0 -18
  119. package/.venv/lib/python3.9/site-packages/pgi/signals.py +0 -122
  120. package/.venv/lib/python3.9/site-packages/pgi/static.py +0 -189
  121. package/.venv/lib/python3.9/site-packages/pgi/structure.py +0 -131
  122. package/.venv/lib/python3.9/site-packages/pgi/util.py +0 -342
  123. package/.venv/lib/python3.9/site-packages/pgi-0.0.11.2.dist-info/COPYING +0 -502
  124. package/.venv/lib/python3.9/site-packages/pgi-0.0.11.2.dist-info/INSTALLER +0 -1
  125. package/.venv/lib/python3.9/site-packages/pgi-0.0.11.2.dist-info/METADATA +0 -22
  126. package/.venv/lib/python3.9/site-packages/pgi-0.0.11.2.dist-info/RECORD +0 -229
  127. package/.venv/lib/python3.9/site-packages/pgi-0.0.11.2.dist-info/REQUESTED +0 -0
  128. package/.venv/lib/python3.9/site-packages/pgi-0.0.11.2.dist-info/WHEEL +0 -5
  129. package/.venv/lib/python3.9/site-packages/pgi-0.0.11.2.dist-info/top_level.txt +0 -1
  130. package/.venv/lib/python3.9/site-packages/pip/__init__.py +0 -13
  131. package/.venv/lib/python3.9/site-packages/pip/__main__.py +0 -31
  132. package/.venv/lib/python3.9/site-packages/pip/_internal/__init__.py +0 -19
  133. package/.venv/lib/python3.9/site-packages/pip/_internal/build_env.py +0 -293
  134. package/.venv/lib/python3.9/site-packages/pip/_internal/cache.py +0 -264
  135. package/.venv/lib/python3.9/site-packages/pip/_internal/cli/__init__.py +0 -4
  136. package/.venv/lib/python3.9/site-packages/pip/_internal/cli/autocompletion.py +0 -163
  137. package/.venv/lib/python3.9/site-packages/pip/_internal/cli/base_command.py +0 -214
  138. package/.venv/lib/python3.9/site-packages/pip/_internal/cli/cmdoptions.py +0 -1010
  139. package/.venv/lib/python3.9/site-packages/pip/_internal/cli/command_context.py +0 -27
  140. package/.venv/lib/python3.9/site-packages/pip/_internal/cli/main.py +0 -70
  141. package/.venv/lib/python3.9/site-packages/pip/_internal/cli/main_parser.py +0 -87
  142. package/.venv/lib/python3.9/site-packages/pip/_internal/cli/parser.py +0 -292
  143. package/.venv/lib/python3.9/site-packages/pip/_internal/cli/progress_bars.py +0 -250
  144. package/.venv/lib/python3.9/site-packages/pip/_internal/cli/req_command.py +0 -469
  145. package/.venv/lib/python3.9/site-packages/pip/_internal/cli/spinners.py +0 -157
  146. package/.venv/lib/python3.9/site-packages/pip/_internal/cli/status_codes.py +0 -6
  147. package/.venv/lib/python3.9/site-packages/pip/_internal/commands/__init__.py +0 -127
  148. package/.venv/lib/python3.9/site-packages/pip/_internal/commands/cache.py +0 -223
  149. package/.venv/lib/python3.9/site-packages/pip/_internal/commands/check.py +0 -53
  150. package/.venv/lib/python3.9/site-packages/pip/_internal/commands/completion.py +0 -96
  151. package/.venv/lib/python3.9/site-packages/pip/_internal/commands/configuration.py +0 -266
  152. package/.venv/lib/python3.9/site-packages/pip/_internal/commands/debug.py +0 -202
  153. package/.venv/lib/python3.9/site-packages/pip/_internal/commands/download.py +0 -139
  154. package/.venv/lib/python3.9/site-packages/pip/_internal/commands/freeze.py +0 -97
  155. package/.venv/lib/python3.9/site-packages/pip/_internal/commands/hash.py +0 -59
  156. package/.venv/lib/python3.9/site-packages/pip/_internal/commands/help.py +0 -41
  157. package/.venv/lib/python3.9/site-packages/pip/_internal/commands/index.py +0 -138
  158. package/.venv/lib/python3.9/site-packages/pip/_internal/commands/install.py +0 -770
  159. package/.venv/lib/python3.9/site-packages/pip/_internal/commands/list.py +0 -361
  160. package/.venv/lib/python3.9/site-packages/pip/_internal/commands/search.py +0 -174
  161. package/.venv/lib/python3.9/site-packages/pip/_internal/commands/show.py +0 -235
  162. package/.venv/lib/python3.9/site-packages/pip/_internal/commands/uninstall.py +0 -105
  163. package/.venv/lib/python3.9/site-packages/pip/_internal/commands/wheel.py +0 -177
  164. package/.venv/lib/python3.9/site-packages/pip/_internal/configuration.py +0 -367
  165. package/.venv/lib/python3.9/site-packages/pip/_internal/distributions/__init__.py +0 -21
  166. package/.venv/lib/python3.9/site-packages/pip/_internal/distributions/base.py +0 -36
  167. package/.venv/lib/python3.9/site-packages/pip/_internal/distributions/installed.py +0 -22
  168. package/.venv/lib/python3.9/site-packages/pip/_internal/distributions/sdist.py +0 -129
  169. package/.venv/lib/python3.9/site-packages/pip/_internal/distributions/wheel.py +0 -31
  170. package/.venv/lib/python3.9/site-packages/pip/_internal/exceptions.py +0 -402
  171. package/.venv/lib/python3.9/site-packages/pip/_internal/index/__init__.py +0 -2
  172. package/.venv/lib/python3.9/site-packages/pip/_internal/index/collector.py +0 -536
  173. package/.venv/lib/python3.9/site-packages/pip/_internal/index/package_finder.py +0 -993
  174. package/.venv/lib/python3.9/site-packages/pip/_internal/index/sources.py +0 -224
  175. package/.venv/lib/python3.9/site-packages/pip/_internal/locations/__init__.py +0 -446
  176. package/.venv/lib/python3.9/site-packages/pip/_internal/locations/_distutils.py +0 -169
  177. package/.venv/lib/python3.9/site-packages/pip/_internal/locations/_sysconfig.py +0 -219
  178. package/.venv/lib/python3.9/site-packages/pip/_internal/locations/base.py +0 -52
  179. package/.venv/lib/python3.9/site-packages/pip/_internal/main.py +0 -12
  180. package/.venv/lib/python3.9/site-packages/pip/_internal/metadata/__init__.py +0 -51
  181. package/.venv/lib/python3.9/site-packages/pip/_internal/metadata/base.py +0 -330
  182. package/.venv/lib/python3.9/site-packages/pip/_internal/metadata/pkg_resources.py +0 -146
  183. package/.venv/lib/python3.9/site-packages/pip/_internal/models/__init__.py +0 -2
  184. package/.venv/lib/python3.9/site-packages/pip/_internal/models/candidate.py +0 -34
  185. package/.venv/lib/python3.9/site-packages/pip/_internal/models/direct_url.py +0 -220
  186. package/.venv/lib/python3.9/site-packages/pip/_internal/models/format_control.py +0 -80
  187. package/.venv/lib/python3.9/site-packages/pip/_internal/models/index.py +0 -28
  188. package/.venv/lib/python3.9/site-packages/pip/_internal/models/link.py +0 -288
  189. package/.venv/lib/python3.9/site-packages/pip/_internal/models/scheme.py +0 -31
  190. package/.venv/lib/python3.9/site-packages/pip/_internal/models/search_scope.py +0 -129
  191. package/.venv/lib/python3.9/site-packages/pip/_internal/models/selection_prefs.py +0 -51
  192. package/.venv/lib/python3.9/site-packages/pip/_internal/models/target_python.py +0 -110
  193. package/.venv/lib/python3.9/site-packages/pip/_internal/models/wheel.py +0 -89
  194. package/.venv/lib/python3.9/site-packages/pip/_internal/network/__init__.py +0 -2
  195. package/.venv/lib/python3.9/site-packages/pip/_internal/network/auth.py +0 -323
  196. package/.venv/lib/python3.9/site-packages/pip/_internal/network/cache.py +0 -69
  197. package/.venv/lib/python3.9/site-packages/pip/_internal/network/download.py +0 -184
  198. package/.venv/lib/python3.9/site-packages/pip/_internal/network/lazy_wheel.py +0 -210
  199. package/.venv/lib/python3.9/site-packages/pip/_internal/network/session.py +0 -454
  200. package/.venv/lib/python3.9/site-packages/pip/_internal/network/utils.py +0 -96
  201. package/.venv/lib/python3.9/site-packages/pip/_internal/network/xmlrpc.py +0 -60
  202. package/.venv/lib/python3.9/site-packages/pip/_internal/operations/__init__.py +0 -0
  203. package/.venv/lib/python3.9/site-packages/pip/_internal/operations/build/__init__.py +0 -0
  204. package/.venv/lib/python3.9/site-packages/pip/_internal/operations/build/metadata.py +0 -30
  205. package/.venv/lib/python3.9/site-packages/pip/_internal/operations/build/metadata_editable.py +0 -34
  206. package/.venv/lib/python3.9/site-packages/pip/_internal/operations/build/metadata_legacy.py +0 -67
  207. package/.venv/lib/python3.9/site-packages/pip/_internal/operations/build/wheel.py +0 -37
  208. package/.venv/lib/python3.9/site-packages/pip/_internal/operations/build/wheel_editable.py +0 -46
  209. package/.venv/lib/python3.9/site-packages/pip/_internal/operations/build/wheel_legacy.py +0 -105
  210. package/.venv/lib/python3.9/site-packages/pip/_internal/operations/check.py +0 -149
  211. package/.venv/lib/python3.9/site-packages/pip/_internal/operations/freeze.py +0 -254
  212. package/.venv/lib/python3.9/site-packages/pip/_internal/operations/install/__init__.py +0 -2
  213. package/.venv/lib/python3.9/site-packages/pip/_internal/operations/install/editable_legacy.py +0 -46
  214. package/.venv/lib/python3.9/site-packages/pip/_internal/operations/install/legacy.py +0 -125
  215. package/.venv/lib/python3.9/site-packages/pip/_internal/operations/install/wheel.py +0 -738
  216. package/.venv/lib/python3.9/site-packages/pip/_internal/operations/prepare.py +0 -632
  217. package/.venv/lib/python3.9/site-packages/pip/_internal/pyproject.py +0 -183
  218. package/.venv/lib/python3.9/site-packages/pip/_internal/req/__init__.py +0 -94
  219. package/.venv/lib/python3.9/site-packages/pip/_internal/req/constructors.py +0 -466
  220. package/.venv/lib/python3.9/site-packages/pip/_internal/req/req_file.py +0 -536
  221. package/.venv/lib/python3.9/site-packages/pip/_internal/req/req_install.py +0 -891
  222. package/.venv/lib/python3.9/site-packages/pip/_internal/req/req_set.py +0 -189
  223. package/.venv/lib/python3.9/site-packages/pip/_internal/req/req_tracker.py +0 -124
  224. package/.venv/lib/python3.9/site-packages/pip/_internal/req/req_uninstall.py +0 -633
  225. package/.venv/lib/python3.9/site-packages/pip/_internal/resolution/__init__.py +0 -0
  226. package/.venv/lib/python3.9/site-packages/pip/_internal/resolution/base.py +0 -20
  227. package/.venv/lib/python3.9/site-packages/pip/_internal/resolution/legacy/__init__.py +0 -0
  228. package/.venv/lib/python3.9/site-packages/pip/_internal/resolution/legacy/resolver.py +0 -467
  229. package/.venv/lib/python3.9/site-packages/pip/_internal/resolution/resolvelib/__init__.py +0 -0
  230. package/.venv/lib/python3.9/site-packages/pip/_internal/resolution/resolvelib/base.py +0 -141
  231. package/.venv/lib/python3.9/site-packages/pip/_internal/resolution/resolvelib/candidates.py +0 -540
  232. package/.venv/lib/python3.9/site-packages/pip/_internal/resolution/resolvelib/factory.py +0 -701
  233. package/.venv/lib/python3.9/site-packages/pip/_internal/resolution/resolvelib/found_candidates.py +0 -155
  234. package/.venv/lib/python3.9/site-packages/pip/_internal/resolution/resolvelib/provider.py +0 -215
  235. package/.venv/lib/python3.9/site-packages/pip/_internal/resolution/resolvelib/reporter.py +0 -68
  236. package/.venv/lib/python3.9/site-packages/pip/_internal/resolution/resolvelib/requirements.py +0 -166
  237. package/.venv/lib/python3.9/site-packages/pip/_internal/resolution/resolvelib/resolver.py +0 -251
  238. package/.venv/lib/python3.9/site-packages/pip/_internal/self_outdated_check.py +0 -182
  239. package/.venv/lib/python3.9/site-packages/pip/_internal/utils/__init__.py +0 -0
  240. package/.venv/lib/python3.9/site-packages/pip/_internal/utils/_log.py +0 -38
  241. package/.venv/lib/python3.9/site-packages/pip/_internal/utils/appdirs.py +0 -52
  242. package/.venv/lib/python3.9/site-packages/pip/_internal/utils/compat.py +0 -63
  243. package/.venv/lib/python3.9/site-packages/pip/_internal/utils/compatibility_tags.py +0 -165
  244. package/.venv/lib/python3.9/site-packages/pip/_internal/utils/datetime.py +0 -11
  245. package/.venv/lib/python3.9/site-packages/pip/_internal/utils/deprecation.py +0 -120
  246. package/.venv/lib/python3.9/site-packages/pip/_internal/utils/direct_url_helpers.py +0 -87
  247. package/.venv/lib/python3.9/site-packages/pip/_internal/utils/distutils_args.py +0 -42
  248. package/.venv/lib/python3.9/site-packages/pip/_internal/utils/egg_link.py +0 -75
  249. package/.venv/lib/python3.9/site-packages/pip/_internal/utils/encoding.py +0 -36
  250. package/.venv/lib/python3.9/site-packages/pip/_internal/utils/entrypoints.py +0 -27
  251. package/.venv/lib/python3.9/site-packages/pip/_internal/utils/filesystem.py +0 -182
  252. package/.venv/lib/python3.9/site-packages/pip/_internal/utils/filetypes.py +0 -27
  253. package/.venv/lib/python3.9/site-packages/pip/_internal/utils/glibc.py +0 -88
  254. package/.venv/lib/python3.9/site-packages/pip/_internal/utils/hashes.py +0 -144
  255. package/.venv/lib/python3.9/site-packages/pip/_internal/utils/inject_securetransport.py +0 -35
  256. package/.venv/lib/python3.9/site-packages/pip/_internal/utils/logging.py +0 -358
  257. package/.venv/lib/python3.9/site-packages/pip/_internal/utils/misc.py +0 -689
  258. package/.venv/lib/python3.9/site-packages/pip/_internal/utils/models.py +0 -39
  259. package/.venv/lib/python3.9/site-packages/pip/_internal/utils/packaging.py +0 -84
  260. package/.venv/lib/python3.9/site-packages/pip/_internal/utils/parallel.py +0 -103
  261. package/.venv/lib/python3.9/site-packages/pip/_internal/utils/pkg_resources.py +0 -33
  262. package/.venv/lib/python3.9/site-packages/pip/_internal/utils/setuptools_build.py +0 -167
  263. package/.venv/lib/python3.9/site-packages/pip/_internal/utils/subprocess.py +0 -289
  264. package/.venv/lib/python3.9/site-packages/pip/_internal/utils/temp_dir.py +0 -246
  265. package/.venv/lib/python3.9/site-packages/pip/_internal/utils/unpacking.py +0 -258
  266. package/.venv/lib/python3.9/site-packages/pip/_internal/utils/urls.py +0 -62
  267. package/.venv/lib/python3.9/site-packages/pip/_internal/utils/virtualenv.py +0 -104
  268. package/.venv/lib/python3.9/site-packages/pip/_internal/utils/wheel.py +0 -182
  269. package/.venv/lib/python3.9/site-packages/pip/_internal/vcs/__init__.py +0 -15
  270. package/.venv/lib/python3.9/site-packages/pip/_internal/vcs/bazaar.py +0 -93
  271. package/.venv/lib/python3.9/site-packages/pip/_internal/vcs/git.py +0 -513
  272. package/.venv/lib/python3.9/site-packages/pip/_internal/vcs/mercurial.py +0 -153
  273. package/.venv/lib/python3.9/site-packages/pip/_internal/vcs/subversion.py +0 -318
  274. package/.venv/lib/python3.9/site-packages/pip/_internal/vcs/versioncontrol.py +0 -693
  275. package/.venv/lib/python3.9/site-packages/pip/_internal/wheel_builder.py +0 -375
  276. package/.venv/lib/python3.9/site-packages/pip/_vendor/__init__.py +0 -111
  277. package/.venv/lib/python3.9/site-packages/pip/_vendor/cachecontrol/__init__.py +0 -11
  278. package/.venv/lib/python3.9/site-packages/pip/_vendor/cachecontrol/_cmd.py +0 -57
  279. package/.venv/lib/python3.9/site-packages/pip/_vendor/cachecontrol/adapter.py +0 -133
  280. package/.venv/lib/python3.9/site-packages/pip/_vendor/cachecontrol/cache.py +0 -39
  281. package/.venv/lib/python3.9/site-packages/pip/_vendor/cachecontrol/caches/__init__.py +0 -2
  282. package/.venv/lib/python3.9/site-packages/pip/_vendor/cachecontrol/caches/file_cache.py +0 -146
  283. package/.venv/lib/python3.9/site-packages/pip/_vendor/cachecontrol/caches/redis_cache.py +0 -33
  284. package/.venv/lib/python3.9/site-packages/pip/_vendor/cachecontrol/compat.py +0 -29
  285. package/.venv/lib/python3.9/site-packages/pip/_vendor/cachecontrol/controller.py +0 -376
  286. package/.venv/lib/python3.9/site-packages/pip/_vendor/cachecontrol/filewrapper.py +0 -80
  287. package/.venv/lib/python3.9/site-packages/pip/_vendor/cachecontrol/heuristics.py +0 -135
  288. package/.venv/lib/python3.9/site-packages/pip/_vendor/cachecontrol/serialize.py +0 -188
  289. package/.venv/lib/python3.9/site-packages/pip/_vendor/cachecontrol/wrapper.py +0 -29
  290. package/.venv/lib/python3.9/site-packages/pip/_vendor/certifi/__init__.py +0 -3
  291. package/.venv/lib/python3.9/site-packages/pip/_vendor/certifi/__main__.py +0 -12
  292. package/.venv/lib/python3.9/site-packages/pip/_vendor/certifi/cacert.pem +0 -4257
  293. package/.venv/lib/python3.9/site-packages/pip/_vendor/certifi/core.py +0 -76
  294. package/.venv/lib/python3.9/site-packages/pip/_vendor/chardet/__init__.py +0 -83
  295. package/.venv/lib/python3.9/site-packages/pip/_vendor/chardet/big5freq.py +0 -386
  296. package/.venv/lib/python3.9/site-packages/pip/_vendor/chardet/big5prober.py +0 -47
  297. package/.venv/lib/python3.9/site-packages/pip/_vendor/chardet/chardistribution.py +0 -233
  298. package/.venv/lib/python3.9/site-packages/pip/_vendor/chardet/charsetgroupprober.py +0 -107
  299. package/.venv/lib/python3.9/site-packages/pip/_vendor/chardet/charsetprober.py +0 -145
  300. package/.venv/lib/python3.9/site-packages/pip/_vendor/chardet/cli/__init__.py +0 -1
  301. package/.venv/lib/python3.9/site-packages/pip/_vendor/chardet/cli/chardetect.py +0 -84
  302. package/.venv/lib/python3.9/site-packages/pip/_vendor/chardet/codingstatemachine.py +0 -88
  303. package/.venv/lib/python3.9/site-packages/pip/_vendor/chardet/compat.py +0 -36
  304. package/.venv/lib/python3.9/site-packages/pip/_vendor/chardet/cp949prober.py +0 -49
  305. package/.venv/lib/python3.9/site-packages/pip/_vendor/chardet/enums.py +0 -76
  306. package/.venv/lib/python3.9/site-packages/pip/_vendor/chardet/escprober.py +0 -101
  307. package/.venv/lib/python3.9/site-packages/pip/_vendor/chardet/escsm.py +0 -246
  308. package/.venv/lib/python3.9/site-packages/pip/_vendor/chardet/eucjpprober.py +0 -92
  309. package/.venv/lib/python3.9/site-packages/pip/_vendor/chardet/euckrfreq.py +0 -195
  310. package/.venv/lib/python3.9/site-packages/pip/_vendor/chardet/euckrprober.py +0 -47
  311. package/.venv/lib/python3.9/site-packages/pip/_vendor/chardet/euctwfreq.py +0 -387
  312. package/.venv/lib/python3.9/site-packages/pip/_vendor/chardet/euctwprober.py +0 -46
  313. package/.venv/lib/python3.9/site-packages/pip/_vendor/chardet/gb2312freq.py +0 -283
  314. package/.venv/lib/python3.9/site-packages/pip/_vendor/chardet/gb2312prober.py +0 -46
  315. package/.venv/lib/python3.9/site-packages/pip/_vendor/chardet/hebrewprober.py +0 -292
  316. package/.venv/lib/python3.9/site-packages/pip/_vendor/chardet/jisfreq.py +0 -325
  317. package/.venv/lib/python3.9/site-packages/pip/_vendor/chardet/jpcntx.py +0 -233
  318. package/.venv/lib/python3.9/site-packages/pip/_vendor/chardet/langbulgarianmodel.py +0 -4650
  319. package/.venv/lib/python3.9/site-packages/pip/_vendor/chardet/langgreekmodel.py +0 -4398
  320. package/.venv/lib/python3.9/site-packages/pip/_vendor/chardet/langhebrewmodel.py +0 -4383
  321. package/.venv/lib/python3.9/site-packages/pip/_vendor/chardet/langhungarianmodel.py +0 -4650
  322. package/.venv/lib/python3.9/site-packages/pip/_vendor/chardet/langrussianmodel.py +0 -5718
  323. package/.venv/lib/python3.9/site-packages/pip/_vendor/chardet/langthaimodel.py +0 -4383
  324. package/.venv/lib/python3.9/site-packages/pip/_vendor/chardet/langturkishmodel.py +0 -4383
  325. package/.venv/lib/python3.9/site-packages/pip/_vendor/chardet/latin1prober.py +0 -145
  326. package/.venv/lib/python3.9/site-packages/pip/_vendor/chardet/mbcharsetprober.py +0 -91
  327. package/.venv/lib/python3.9/site-packages/pip/_vendor/chardet/mbcsgroupprober.py +0 -54
  328. package/.venv/lib/python3.9/site-packages/pip/_vendor/chardet/mbcssm.py +0 -572
  329. package/.venv/lib/python3.9/site-packages/pip/_vendor/chardet/metadata/__init__.py +0 -0
  330. package/.venv/lib/python3.9/site-packages/pip/_vendor/chardet/metadata/languages.py +0 -310
  331. package/.venv/lib/python3.9/site-packages/pip/_vendor/chardet/sbcharsetprober.py +0 -145
  332. package/.venv/lib/python3.9/site-packages/pip/_vendor/chardet/sbcsgroupprober.py +0 -83
  333. package/.venv/lib/python3.9/site-packages/pip/_vendor/chardet/sjisprober.py +0 -92
  334. package/.venv/lib/python3.9/site-packages/pip/_vendor/chardet/universaldetector.py +0 -286
  335. package/.venv/lib/python3.9/site-packages/pip/_vendor/chardet/utf8prober.py +0 -82
  336. package/.venv/lib/python3.9/site-packages/pip/_vendor/chardet/version.py +0 -9
  337. package/.venv/lib/python3.9/site-packages/pip/_vendor/colorama/__init__.py +0 -6
  338. package/.venv/lib/python3.9/site-packages/pip/_vendor/colorama/ansi.py +0 -102
  339. package/.venv/lib/python3.9/site-packages/pip/_vendor/colorama/ansitowin32.py +0 -258
  340. package/.venv/lib/python3.9/site-packages/pip/_vendor/colorama/initialise.py +0 -80
  341. package/.venv/lib/python3.9/site-packages/pip/_vendor/colorama/win32.py +0 -152
  342. package/.venv/lib/python3.9/site-packages/pip/_vendor/colorama/winterm.py +0 -169
  343. package/.venv/lib/python3.9/site-packages/pip/_vendor/distlib/__init__.py +0 -23
  344. package/.venv/lib/python3.9/site-packages/pip/_vendor/distlib/_backport/__init__.py +0 -6
  345. package/.venv/lib/python3.9/site-packages/pip/_vendor/distlib/_backport/misc.py +0 -41
  346. package/.venv/lib/python3.9/site-packages/pip/_vendor/distlib/_backport/shutil.py +0 -764
  347. package/.venv/lib/python3.9/site-packages/pip/_vendor/distlib/_backport/sysconfig.cfg +0 -84
  348. package/.venv/lib/python3.9/site-packages/pip/_vendor/distlib/_backport/sysconfig.py +0 -786
  349. package/.venv/lib/python3.9/site-packages/pip/_vendor/distlib/_backport/tarfile.py +0 -2607
  350. package/.venv/lib/python3.9/site-packages/pip/_vendor/distlib/compat.py +0 -1122
  351. package/.venv/lib/python3.9/site-packages/pip/_vendor/distlib/database.py +0 -1339
  352. package/.venv/lib/python3.9/site-packages/pip/_vendor/distlib/index.py +0 -509
  353. package/.venv/lib/python3.9/site-packages/pip/_vendor/distlib/locators.py +0 -1300
  354. package/.venv/lib/python3.9/site-packages/pip/_vendor/distlib/manifest.py +0 -393
  355. package/.venv/lib/python3.9/site-packages/pip/_vendor/distlib/markers.py +0 -147
  356. package/.venv/lib/python3.9/site-packages/pip/_vendor/distlib/metadata.py +0 -1058
  357. package/.venv/lib/python3.9/site-packages/pip/_vendor/distlib/resources.py +0 -358
  358. package/.venv/lib/python3.9/site-packages/pip/_vendor/distlib/scripts.py +0 -429
  359. package/.venv/lib/python3.9/site-packages/pip/_vendor/distlib/t32.exe +0 -0
  360. package/.venv/lib/python3.9/site-packages/pip/_vendor/distlib/t64-arm.exe +0 -0
  361. package/.venv/lib/python3.9/site-packages/pip/_vendor/distlib/t64.exe +0 -0
  362. package/.venv/lib/python3.9/site-packages/pip/_vendor/distlib/util.py +0 -1969
  363. package/.venv/lib/python3.9/site-packages/pip/_vendor/distlib/version.py +0 -739
  364. package/.venv/lib/python3.9/site-packages/pip/_vendor/distlib/w32.exe +0 -0
  365. package/.venv/lib/python3.9/site-packages/pip/_vendor/distlib/w64-arm.exe +0 -0
  366. package/.venv/lib/python3.9/site-packages/pip/_vendor/distlib/w64.exe +0 -0
  367. package/.venv/lib/python3.9/site-packages/pip/_vendor/distlib/wheel.py +0 -1053
  368. package/.venv/lib/python3.9/site-packages/pip/_vendor/distro.py +0 -1386
  369. package/.venv/lib/python3.9/site-packages/pip/_vendor/html5lib/__init__.py +0 -35
  370. package/.venv/lib/python3.9/site-packages/pip/_vendor/html5lib/_ihatexml.py +0 -289
  371. package/.venv/lib/python3.9/site-packages/pip/_vendor/html5lib/_inputstream.py +0 -918
  372. package/.venv/lib/python3.9/site-packages/pip/_vendor/html5lib/_tokenizer.py +0 -1735
  373. package/.venv/lib/python3.9/site-packages/pip/_vendor/html5lib/_trie/__init__.py +0 -5
  374. package/.venv/lib/python3.9/site-packages/pip/_vendor/html5lib/_trie/_base.py +0 -40
  375. package/.venv/lib/python3.9/site-packages/pip/_vendor/html5lib/_trie/py.py +0 -67
  376. package/.venv/lib/python3.9/site-packages/pip/_vendor/html5lib/_utils.py +0 -159
  377. package/.venv/lib/python3.9/site-packages/pip/_vendor/html5lib/constants.py +0 -2946
  378. package/.venv/lib/python3.9/site-packages/pip/_vendor/html5lib/filters/__init__.py +0 -0
  379. package/.venv/lib/python3.9/site-packages/pip/_vendor/html5lib/filters/alphabeticalattributes.py +0 -29
  380. package/.venv/lib/python3.9/site-packages/pip/_vendor/html5lib/filters/base.py +0 -12
  381. package/.venv/lib/python3.9/site-packages/pip/_vendor/html5lib/filters/inject_meta_charset.py +0 -73
  382. package/.venv/lib/python3.9/site-packages/pip/_vendor/html5lib/filters/lint.py +0 -93
  383. package/.venv/lib/python3.9/site-packages/pip/_vendor/html5lib/filters/optionaltags.py +0 -207
  384. package/.venv/lib/python3.9/site-packages/pip/_vendor/html5lib/filters/sanitizer.py +0 -916
  385. package/.venv/lib/python3.9/site-packages/pip/_vendor/html5lib/filters/whitespace.py +0 -38
  386. package/.venv/lib/python3.9/site-packages/pip/_vendor/html5lib/html5parser.py +0 -2795
  387. package/.venv/lib/python3.9/site-packages/pip/_vendor/html5lib/serializer.py +0 -409
  388. package/.venv/lib/python3.9/site-packages/pip/_vendor/html5lib/treeadapters/__init__.py +0 -30
  389. package/.venv/lib/python3.9/site-packages/pip/_vendor/html5lib/treeadapters/genshi.py +0 -54
  390. package/.venv/lib/python3.9/site-packages/pip/_vendor/html5lib/treeadapters/sax.py +0 -50
  391. package/.venv/lib/python3.9/site-packages/pip/_vendor/html5lib/treebuilders/__init__.py +0 -88
  392. package/.venv/lib/python3.9/site-packages/pip/_vendor/html5lib/treebuilders/base.py +0 -417
  393. package/.venv/lib/python3.9/site-packages/pip/_vendor/html5lib/treebuilders/dom.py +0 -239
  394. package/.venv/lib/python3.9/site-packages/pip/_vendor/html5lib/treebuilders/etree.py +0 -343
  395. package/.venv/lib/python3.9/site-packages/pip/_vendor/html5lib/treebuilders/etree_lxml.py +0 -392
  396. package/.venv/lib/python3.9/site-packages/pip/_vendor/html5lib/treewalkers/__init__.py +0 -154
  397. package/.venv/lib/python3.9/site-packages/pip/_vendor/html5lib/treewalkers/base.py +0 -252
  398. package/.venv/lib/python3.9/site-packages/pip/_vendor/html5lib/treewalkers/dom.py +0 -43
  399. package/.venv/lib/python3.9/site-packages/pip/_vendor/html5lib/treewalkers/etree.py +0 -131
  400. package/.venv/lib/python3.9/site-packages/pip/_vendor/html5lib/treewalkers/etree_lxml.py +0 -215
  401. package/.venv/lib/python3.9/site-packages/pip/_vendor/html5lib/treewalkers/genshi.py +0 -69
  402. package/.venv/lib/python3.9/site-packages/pip/_vendor/idna/__init__.py +0 -44
  403. package/.venv/lib/python3.9/site-packages/pip/_vendor/idna/codec.py +0 -117
  404. package/.venv/lib/python3.9/site-packages/pip/_vendor/idna/compat.py +0 -16
  405. package/.venv/lib/python3.9/site-packages/pip/_vendor/idna/core.py +0 -409
  406. package/.venv/lib/python3.9/site-packages/pip/_vendor/idna/idnadata.py +0 -2050
  407. package/.venv/lib/python3.9/site-packages/pip/_vendor/idna/intranges.py +0 -58
  408. package/.venv/lib/python3.9/site-packages/pip/_vendor/idna/package_data.py +0 -2
  409. package/.venv/lib/python3.9/site-packages/pip/_vendor/idna/uts46data.py +0 -8438
  410. package/.venv/lib/python3.9/site-packages/pip/_vendor/msgpack/__init__.py +0 -54
  411. package/.venv/lib/python3.9/site-packages/pip/_vendor/msgpack/_version.py +0 -1
  412. package/.venv/lib/python3.9/site-packages/pip/_vendor/msgpack/exceptions.py +0 -48
  413. package/.venv/lib/python3.9/site-packages/pip/_vendor/msgpack/ext.py +0 -193
  414. package/.venv/lib/python3.9/site-packages/pip/_vendor/msgpack/fallback.py +0 -1087
  415. package/.venv/lib/python3.9/site-packages/pip/_vendor/packaging/__about__.py +0 -26
  416. package/.venv/lib/python3.9/site-packages/pip/_vendor/packaging/__init__.py +0 -25
  417. package/.venv/lib/python3.9/site-packages/pip/_vendor/packaging/_manylinux.py +0 -301
  418. package/.venv/lib/python3.9/site-packages/pip/_vendor/packaging/_musllinux.py +0 -136
  419. package/.venv/lib/python3.9/site-packages/pip/_vendor/packaging/_structures.py +0 -67
  420. package/.venv/lib/python3.9/site-packages/pip/_vendor/packaging/markers.py +0 -304
  421. package/.venv/lib/python3.9/site-packages/pip/_vendor/packaging/requirements.py +0 -146
  422. package/.venv/lib/python3.9/site-packages/pip/_vendor/packaging/specifiers.py +0 -828
  423. package/.venv/lib/python3.9/site-packages/pip/_vendor/packaging/tags.py +0 -484
  424. package/.venv/lib/python3.9/site-packages/pip/_vendor/packaging/utils.py +0 -136
  425. package/.venv/lib/python3.9/site-packages/pip/_vendor/packaging/version.py +0 -504
  426. package/.venv/lib/python3.9/site-packages/pip/_vendor/pep517/__init__.py +0 -6
  427. package/.venv/lib/python3.9/site-packages/pip/_vendor/pep517/build.py +0 -127
  428. package/.venv/lib/python3.9/site-packages/pip/_vendor/pep517/check.py +0 -207
  429. package/.venv/lib/python3.9/site-packages/pip/_vendor/pep517/colorlog.py +0 -115
  430. package/.venv/lib/python3.9/site-packages/pip/_vendor/pep517/compat.py +0 -51
  431. package/.venv/lib/python3.9/site-packages/pip/_vendor/pep517/dirtools.py +0 -44
  432. package/.venv/lib/python3.9/site-packages/pip/_vendor/pep517/envbuild.py +0 -171
  433. package/.venv/lib/python3.9/site-packages/pip/_vendor/pep517/in_process/__init__.py +0 -17
  434. package/.venv/lib/python3.9/site-packages/pip/_vendor/pep517/in_process/_in_process.py +0 -363
  435. package/.venv/lib/python3.9/site-packages/pip/_vendor/pep517/meta.py +0 -92
  436. package/.venv/lib/python3.9/site-packages/pip/_vendor/pep517/wrappers.py +0 -375
  437. package/.venv/lib/python3.9/site-packages/pip/_vendor/pkg_resources/__init__.py +0 -3296
  438. package/.venv/lib/python3.9/site-packages/pip/_vendor/pkg_resources/py31compat.py +0 -23
  439. package/.venv/lib/python3.9/site-packages/pip/_vendor/platformdirs/__init__.py +0 -329
  440. package/.venv/lib/python3.9/site-packages/pip/_vendor/platformdirs/__main__.py +0 -44
  441. package/.venv/lib/python3.9/site-packages/pip/_vendor/platformdirs/android.py +0 -117
  442. package/.venv/lib/python3.9/site-packages/pip/_vendor/platformdirs/api.py +0 -155
  443. package/.venv/lib/python3.9/site-packages/pip/_vendor/platformdirs/macos.py +0 -62
  444. package/.venv/lib/python3.9/site-packages/pip/_vendor/platformdirs/unix.py +0 -180
  445. package/.venv/lib/python3.9/site-packages/pip/_vendor/platformdirs/version.py +0 -4
  446. package/.venv/lib/python3.9/site-packages/pip/_vendor/platformdirs/windows.py +0 -180
  447. package/.venv/lib/python3.9/site-packages/pip/_vendor/progress/__init__.py +0 -189
  448. package/.venv/lib/python3.9/site-packages/pip/_vendor/progress/bar.py +0 -93
  449. package/.venv/lib/python3.9/site-packages/pip/_vendor/progress/colors.py +0 -79
  450. package/.venv/lib/python3.9/site-packages/pip/_vendor/progress/counter.py +0 -47
  451. package/.venv/lib/python3.9/site-packages/pip/_vendor/progress/spinner.py +0 -45
  452. package/.venv/lib/python3.9/site-packages/pip/_vendor/pyparsing.py +0 -7107
  453. package/.venv/lib/python3.9/site-packages/pip/_vendor/requests/__init__.py +0 -154
  454. package/.venv/lib/python3.9/site-packages/pip/_vendor/requests/__version__.py +0 -14
  455. package/.venv/lib/python3.9/site-packages/pip/_vendor/requests/_internal_utils.py +0 -42
  456. package/.venv/lib/python3.9/site-packages/pip/_vendor/requests/adapters.py +0 -533
  457. package/.venv/lib/python3.9/site-packages/pip/_vendor/requests/api.py +0 -159
  458. package/.venv/lib/python3.9/site-packages/pip/_vendor/requests/auth.py +0 -305
  459. package/.venv/lib/python3.9/site-packages/pip/_vendor/requests/certs.py +0 -18
  460. package/.venv/lib/python3.9/site-packages/pip/_vendor/requests/compat.py +0 -76
  461. package/.venv/lib/python3.9/site-packages/pip/_vendor/requests/cookies.py +0 -549
  462. package/.venv/lib/python3.9/site-packages/pip/_vendor/requests/exceptions.py +0 -127
  463. package/.venv/lib/python3.9/site-packages/pip/_vendor/requests/help.py +0 -132
  464. package/.venv/lib/python3.9/site-packages/pip/_vendor/requests/hooks.py +0 -34
  465. package/.venv/lib/python3.9/site-packages/pip/_vendor/requests/models.py +0 -966
  466. package/.venv/lib/python3.9/site-packages/pip/_vendor/requests/packages.py +0 -16
  467. package/.venv/lib/python3.9/site-packages/pip/_vendor/requests/sessions.py +0 -781
  468. package/.venv/lib/python3.9/site-packages/pip/_vendor/requests/status_codes.py +0 -123
  469. package/.venv/lib/python3.9/site-packages/pip/_vendor/requests/structures.py +0 -105
  470. package/.venv/lib/python3.9/site-packages/pip/_vendor/requests/utils.py +0 -1013
  471. package/.venv/lib/python3.9/site-packages/pip/_vendor/resolvelib/__init__.py +0 -26
  472. package/.venv/lib/python3.9/site-packages/pip/_vendor/resolvelib/compat/__init__.py +0 -0
  473. package/.venv/lib/python3.9/site-packages/pip/_vendor/resolvelib/compat/collections_abc.py +0 -6
  474. package/.venv/lib/python3.9/site-packages/pip/_vendor/resolvelib/providers.py +0 -133
  475. package/.venv/lib/python3.9/site-packages/pip/_vendor/resolvelib/reporters.py +0 -37
  476. package/.venv/lib/python3.9/site-packages/pip/_vendor/resolvelib/resolvers.py +0 -483
  477. package/.venv/lib/python3.9/site-packages/pip/_vendor/resolvelib/structs.py +0 -165
  478. package/.venv/lib/python3.9/site-packages/pip/_vendor/six.py +0 -998
  479. package/.venv/lib/python3.9/site-packages/pip/_vendor/tenacity/__init__.py +0 -517
  480. package/.venv/lib/python3.9/site-packages/pip/_vendor/tenacity/_asyncio.py +0 -92
  481. package/.venv/lib/python3.9/site-packages/pip/_vendor/tenacity/_utils.py +0 -68
  482. package/.venv/lib/python3.9/site-packages/pip/_vendor/tenacity/after.py +0 -46
  483. package/.venv/lib/python3.9/site-packages/pip/_vendor/tenacity/before.py +0 -41
  484. package/.venv/lib/python3.9/site-packages/pip/_vendor/tenacity/before_sleep.py +0 -58
  485. package/.venv/lib/python3.9/site-packages/pip/_vendor/tenacity/nap.py +0 -43
  486. package/.venv/lib/python3.9/site-packages/pip/_vendor/tenacity/retry.py +0 -213
  487. package/.venv/lib/python3.9/site-packages/pip/_vendor/tenacity/stop.py +0 -96
  488. package/.venv/lib/python3.9/site-packages/pip/_vendor/tenacity/tornadoweb.py +0 -59
  489. package/.venv/lib/python3.9/site-packages/pip/_vendor/tenacity/wait.py +0 -191
  490. package/.venv/lib/python3.9/site-packages/pip/_vendor/tomli/__init__.py +0 -6
  491. package/.venv/lib/python3.9/site-packages/pip/_vendor/tomli/_parser.py +0 -703
  492. package/.venv/lib/python3.9/site-packages/pip/_vendor/tomli/_re.py +0 -83
  493. package/.venv/lib/python3.9/site-packages/pip/_vendor/urllib3/__init__.py +0 -85
  494. package/.venv/lib/python3.9/site-packages/pip/_vendor/urllib3/_collections.py +0 -337
  495. package/.venv/lib/python3.9/site-packages/pip/_vendor/urllib3/_version.py +0 -2
  496. package/.venv/lib/python3.9/site-packages/pip/_vendor/urllib3/connection.py +0 -569
  497. package/.venv/lib/python3.9/site-packages/pip/_vendor/urllib3/connectionpool.py +0 -1078
  498. package/.venv/lib/python3.9/site-packages/pip/_vendor/urllib3/contrib/__init__.py +0 -0
  499. package/.venv/lib/python3.9/site-packages/pip/_vendor/urllib3/contrib/_appengine_environ.py +0 -36
  500. package/.venv/lib/python3.9/site-packages/pip/_vendor/urllib3/contrib/_securetransport/__init__.py +0 -0
  501. package/.venv/lib/python3.9/site-packages/pip/_vendor/urllib3/contrib/_securetransport/bindings.py +0 -519
  502. package/.venv/lib/python3.9/site-packages/pip/_vendor/urllib3/contrib/_securetransport/low_level.py +0 -397
  503. package/.venv/lib/python3.9/site-packages/pip/_vendor/urllib3/contrib/appengine.py +0 -314
  504. package/.venv/lib/python3.9/site-packages/pip/_vendor/urllib3/contrib/ntlmpool.py +0 -130
  505. package/.venv/lib/python3.9/site-packages/pip/_vendor/urllib3/contrib/pyopenssl.py +0 -511
  506. package/.venv/lib/python3.9/site-packages/pip/_vendor/urllib3/contrib/securetransport.py +0 -922
  507. package/.venv/lib/python3.9/site-packages/pip/_vendor/urllib3/contrib/socks.py +0 -216
  508. package/.venv/lib/python3.9/site-packages/pip/_vendor/urllib3/exceptions.py +0 -323
  509. package/.venv/lib/python3.9/site-packages/pip/_vendor/urllib3/fields.py +0 -274
  510. package/.venv/lib/python3.9/site-packages/pip/_vendor/urllib3/filepost.py +0 -98
  511. package/.venv/lib/python3.9/site-packages/pip/_vendor/urllib3/packages/__init__.py +0 -5
  512. package/.venv/lib/python3.9/site-packages/pip/_vendor/urllib3/packages/backports/__init__.py +0 -0
  513. package/.venv/lib/python3.9/site-packages/pip/_vendor/urllib3/packages/backports/makefile.py +0 -51
  514. package/.venv/lib/python3.9/site-packages/pip/_vendor/urllib3/packages/six.py +0 -1077
  515. package/.venv/lib/python3.9/site-packages/pip/_vendor/urllib3/packages/ssl_match_hostname/__init__.py +0 -24
  516. package/.venv/lib/python3.9/site-packages/pip/_vendor/urllib3/packages/ssl_match_hostname/_implementation.py +0 -160
  517. package/.venv/lib/python3.9/site-packages/pip/_vendor/urllib3/poolmanager.py +0 -536
  518. package/.venv/lib/python3.9/site-packages/pip/_vendor/urllib3/request.py +0 -170
  519. package/.venv/lib/python3.9/site-packages/pip/_vendor/urllib3/response.py +0 -821
  520. package/.venv/lib/python3.9/site-packages/pip/_vendor/urllib3/util/__init__.py +0 -49
  521. package/.venv/lib/python3.9/site-packages/pip/_vendor/urllib3/util/connection.py +0 -150
  522. package/.venv/lib/python3.9/site-packages/pip/_vendor/urllib3/util/proxy.py +0 -57
  523. package/.venv/lib/python3.9/site-packages/pip/_vendor/urllib3/util/queue.py +0 -22
  524. package/.venv/lib/python3.9/site-packages/pip/_vendor/urllib3/util/request.py +0 -143
  525. package/.venv/lib/python3.9/site-packages/pip/_vendor/urllib3/util/response.py +0 -107
  526. package/.venv/lib/python3.9/site-packages/pip/_vendor/urllib3/util/retry.py +0 -602
  527. package/.venv/lib/python3.9/site-packages/pip/_vendor/urllib3/util/ssl_.py +0 -495
  528. package/.venv/lib/python3.9/site-packages/pip/_vendor/urllib3/util/ssltransport.py +0 -221
  529. package/.venv/lib/python3.9/site-packages/pip/_vendor/urllib3/util/timeout.py +0 -268
  530. package/.venv/lib/python3.9/site-packages/pip/_vendor/urllib3/util/url.py +0 -432
  531. package/.venv/lib/python3.9/site-packages/pip/_vendor/urllib3/util/wait.py +0 -153
  532. package/.venv/lib/python3.9/site-packages/pip/_vendor/vendor.txt +0 -22
  533. package/.venv/lib/python3.9/site-packages/pip/_vendor/webencodings/__init__.py +0 -342
  534. package/.venv/lib/python3.9/site-packages/pip/_vendor/webencodings/labels.py +0 -231
  535. package/.venv/lib/python3.9/site-packages/pip/_vendor/webencodings/mklabels.py +0 -59
  536. package/.venv/lib/python3.9/site-packages/pip/_vendor/webencodings/tests.py +0 -153
  537. package/.venv/lib/python3.9/site-packages/pip/_vendor/webencodings/x_user_defined.py +0 -325
  538. package/.venv/lib/python3.9/site-packages/pip/py.typed +0 -4
  539. package/.venv/lib/python3.9/site-packages/pip-21.3.1.dist-info/INSTALLER +0 -1
  540. package/.venv/lib/python3.9/site-packages/pip-21.3.1.dist-info/LICENSE.txt +0 -20
  541. package/.venv/lib/python3.9/site-packages/pip-21.3.1.dist-info/METADATA +0 -93
  542. package/.venv/lib/python3.9/site-packages/pip-21.3.1.dist-info/RECORD +0 -819
  543. package/.venv/lib/python3.9/site-packages/pip-21.3.1.dist-info/REQUESTED +0 -0
  544. package/.venv/lib/python3.9/site-packages/pip-21.3.1.dist-info/WHEEL +0 -5
  545. package/.venv/lib/python3.9/site-packages/pip-21.3.1.dist-info/entry_points.txt +0 -5
  546. package/.venv/lib/python3.9/site-packages/pip-21.3.1.dist-info/top_level.txt +0 -1
  547. package/.venv/lib/python3.9/site-packages/pkg_resources/__init__.py +0 -3303
  548. package/.venv/lib/python3.9/site-packages/pkg_resources/_vendor/__init__.py +0 -0
  549. package/.venv/lib/python3.9/site-packages/pkg_resources/_vendor/appdirs.py +0 -608
  550. package/.venv/lib/python3.9/site-packages/pkg_resources/_vendor/packaging/__about__.py +0 -26
  551. package/.venv/lib/python3.9/site-packages/pkg_resources/_vendor/packaging/__init__.py +0 -25
  552. package/.venv/lib/python3.9/site-packages/pkg_resources/_vendor/packaging/_manylinux.py +0 -301
  553. package/.venv/lib/python3.9/site-packages/pkg_resources/_vendor/packaging/_musllinux.py +0 -136
  554. package/.venv/lib/python3.9/site-packages/pkg_resources/_vendor/packaging/_structures.py +0 -67
  555. package/.venv/lib/python3.9/site-packages/pkg_resources/_vendor/packaging/markers.py +0 -304
  556. package/.venv/lib/python3.9/site-packages/pkg_resources/_vendor/packaging/requirements.py +0 -146
  557. package/.venv/lib/python3.9/site-packages/pkg_resources/_vendor/packaging/specifiers.py +0 -828
  558. package/.venv/lib/python3.9/site-packages/pkg_resources/_vendor/packaging/tags.py +0 -484
  559. package/.venv/lib/python3.9/site-packages/pkg_resources/_vendor/packaging/utils.py +0 -136
  560. package/.venv/lib/python3.9/site-packages/pkg_resources/_vendor/packaging/version.py +0 -504
  561. package/.venv/lib/python3.9/site-packages/pkg_resources/_vendor/pyparsing.py +0 -5742
  562. package/.venv/lib/python3.9/site-packages/pkg_resources/extern/__init__.py +0 -73
  563. package/.venv/lib/python3.9/site-packages/pkg_resources/tests/data/my-test-package-source/setup.py +0 -6
  564. package/.venv/lib/python3.9/site-packages/setuptools/__init__.py +0 -244
  565. package/.venv/lib/python3.9/site-packages/setuptools/_deprecation_warning.py +0 -7
  566. package/.venv/lib/python3.9/site-packages/setuptools/_distutils/__init__.py +0 -24
  567. package/.venv/lib/python3.9/site-packages/setuptools/_distutils/_collections.py +0 -56
  568. package/.venv/lib/python3.9/site-packages/setuptools/_distutils/_msvccompiler.py +0 -561
  569. package/.venv/lib/python3.9/site-packages/setuptools/_distutils/archive_util.py +0 -256
  570. package/.venv/lib/python3.9/site-packages/setuptools/_distutils/bcppcompiler.py +0 -393
  571. package/.venv/lib/python3.9/site-packages/setuptools/_distutils/ccompiler.py +0 -1123
  572. package/.venv/lib/python3.9/site-packages/setuptools/_distutils/cmd.py +0 -403
  573. package/.venv/lib/python3.9/site-packages/setuptools/_distutils/command/__init__.py +0 -31
  574. package/.venv/lib/python3.9/site-packages/setuptools/_distutils/command/bdist.py +0 -143
  575. package/.venv/lib/python3.9/site-packages/setuptools/_distutils/command/bdist_dumb.py +0 -123
  576. package/.venv/lib/python3.9/site-packages/setuptools/_distutils/command/bdist_msi.py +0 -749
  577. package/.venv/lib/python3.9/site-packages/setuptools/_distutils/command/bdist_rpm.py +0 -579
  578. package/.venv/lib/python3.9/site-packages/setuptools/_distutils/command/bdist_wininst.py +0 -377
  579. package/.venv/lib/python3.9/site-packages/setuptools/_distutils/command/build.py +0 -157
  580. package/.venv/lib/python3.9/site-packages/setuptools/_distutils/command/build_clib.py +0 -209
  581. package/.venv/lib/python3.9/site-packages/setuptools/_distutils/command/build_ext.py +0 -755
  582. package/.venv/lib/python3.9/site-packages/setuptools/_distutils/command/build_py.py +0 -392
  583. package/.venv/lib/python3.9/site-packages/setuptools/_distutils/command/build_scripts.py +0 -152
  584. package/.venv/lib/python3.9/site-packages/setuptools/_distutils/command/check.py +0 -148
  585. package/.venv/lib/python3.9/site-packages/setuptools/_distutils/command/clean.py +0 -76
  586. package/.venv/lib/python3.9/site-packages/setuptools/_distutils/command/config.py +0 -344
  587. package/.venv/lib/python3.9/site-packages/setuptools/_distutils/command/install.py +0 -775
  588. package/.venv/lib/python3.9/site-packages/setuptools/_distutils/command/install_data.py +0 -79
  589. package/.venv/lib/python3.9/site-packages/setuptools/_distutils/command/install_egg_info.py +0 -84
  590. package/.venv/lib/python3.9/site-packages/setuptools/_distutils/command/install_headers.py +0 -47
  591. package/.venv/lib/python3.9/site-packages/setuptools/_distutils/command/install_lib.py +0 -217
  592. package/.venv/lib/python3.9/site-packages/setuptools/_distutils/command/install_scripts.py +0 -60
  593. package/.venv/lib/python3.9/site-packages/setuptools/_distutils/command/py37compat.py +0 -30
  594. package/.venv/lib/python3.9/site-packages/setuptools/_distutils/command/register.py +0 -304
  595. package/.venv/lib/python3.9/site-packages/setuptools/_distutils/command/sdist.py +0 -494
  596. package/.venv/lib/python3.9/site-packages/setuptools/_distutils/command/upload.py +0 -214
  597. package/.venv/lib/python3.9/site-packages/setuptools/_distutils/config.py +0 -130
  598. package/.venv/lib/python3.9/site-packages/setuptools/_distutils/core.py +0 -249
  599. package/.venv/lib/python3.9/site-packages/setuptools/_distutils/cygwinccompiler.py +0 -362
  600. package/.venv/lib/python3.9/site-packages/setuptools/_distutils/debug.py +0 -5
  601. package/.venv/lib/python3.9/site-packages/setuptools/_distutils/dep_util.py +0 -92
  602. package/.venv/lib/python3.9/site-packages/setuptools/_distutils/dir_util.py +0 -210
  603. package/.venv/lib/python3.9/site-packages/setuptools/_distutils/dist.py +0 -1257
  604. package/.venv/lib/python3.9/site-packages/setuptools/_distutils/errors.py +0 -97
  605. package/.venv/lib/python3.9/site-packages/setuptools/_distutils/extension.py +0 -240
  606. package/.venv/lib/python3.9/site-packages/setuptools/_distutils/fancy_getopt.py +0 -457
  607. package/.venv/lib/python3.9/site-packages/setuptools/_distutils/file_util.py +0 -238
  608. package/.venv/lib/python3.9/site-packages/setuptools/_distutils/filelist.py +0 -355
  609. package/.venv/lib/python3.9/site-packages/setuptools/_distutils/log.py +0 -81
  610. package/.venv/lib/python3.9/site-packages/setuptools/_distutils/msvc9compiler.py +0 -788
  611. package/.venv/lib/python3.9/site-packages/setuptools/_distutils/msvccompiler.py +0 -643
  612. package/.venv/lib/python3.9/site-packages/setuptools/_distutils/py35compat.py +0 -19
  613. package/.venv/lib/python3.9/site-packages/setuptools/_distutils/py38compat.py +0 -7
  614. package/.venv/lib/python3.9/site-packages/setuptools/_distutils/spawn.py +0 -106
  615. package/.venv/lib/python3.9/site-packages/setuptools/_distutils/sysconfig.py +0 -567
  616. package/.venv/lib/python3.9/site-packages/setuptools/_distutils/text_file.py +0 -286
  617. package/.venv/lib/python3.9/site-packages/setuptools/_distutils/unixccompiler.py +0 -325
  618. package/.venv/lib/python3.9/site-packages/setuptools/_distutils/util.py +0 -548
  619. package/.venv/lib/python3.9/site-packages/setuptools/_distutils/version.py +0 -363
  620. package/.venv/lib/python3.9/site-packages/setuptools/_distutils/versionpredicate.py +0 -169
  621. package/.venv/lib/python3.9/site-packages/setuptools/_imp.py +0 -82
  622. package/.venv/lib/python3.9/site-packages/setuptools/_vendor/__init__.py +0 -0
  623. package/.venv/lib/python3.9/site-packages/setuptools/_vendor/more_itertools/__init__.py +0 -4
  624. package/.venv/lib/python3.9/site-packages/setuptools/_vendor/more_itertools/more.py +0 -3825
  625. package/.venv/lib/python3.9/site-packages/setuptools/_vendor/more_itertools/recipes.py +0 -620
  626. package/.venv/lib/python3.9/site-packages/setuptools/_vendor/ordered_set.py +0 -488
  627. package/.venv/lib/python3.9/site-packages/setuptools/_vendor/packaging/__about__.py +0 -26
  628. package/.venv/lib/python3.9/site-packages/setuptools/_vendor/packaging/__init__.py +0 -25
  629. package/.venv/lib/python3.9/site-packages/setuptools/_vendor/packaging/_manylinux.py +0 -301
  630. package/.venv/lib/python3.9/site-packages/setuptools/_vendor/packaging/_musllinux.py +0 -136
  631. package/.venv/lib/python3.9/site-packages/setuptools/_vendor/packaging/_structures.py +0 -67
  632. package/.venv/lib/python3.9/site-packages/setuptools/_vendor/packaging/markers.py +0 -304
  633. package/.venv/lib/python3.9/site-packages/setuptools/_vendor/packaging/requirements.py +0 -146
  634. package/.venv/lib/python3.9/site-packages/setuptools/_vendor/packaging/specifiers.py +0 -828
  635. package/.venv/lib/python3.9/site-packages/setuptools/_vendor/packaging/tags.py +0 -484
  636. package/.venv/lib/python3.9/site-packages/setuptools/_vendor/packaging/utils.py +0 -136
  637. package/.venv/lib/python3.9/site-packages/setuptools/_vendor/packaging/version.py +0 -504
  638. package/.venv/lib/python3.9/site-packages/setuptools/_vendor/pyparsing.py +0 -5742
  639. package/.venv/lib/python3.9/site-packages/setuptools/archive_util.py +0 -205
  640. package/.venv/lib/python3.9/site-packages/setuptools/build_meta.py +0 -290
  641. package/.venv/lib/python3.9/site-packages/setuptools/cli-32.exe +0 -0
  642. package/.venv/lib/python3.9/site-packages/setuptools/cli-64.exe +0 -0
  643. package/.venv/lib/python3.9/site-packages/setuptools/cli-arm64.exe +0 -0
  644. package/.venv/lib/python3.9/site-packages/setuptools/cli.exe +0 -0
  645. package/.venv/lib/python3.9/site-packages/setuptools/command/__init__.py +0 -8
  646. package/.venv/lib/python3.9/site-packages/setuptools/command/alias.py +0 -78
  647. package/.venv/lib/python3.9/site-packages/setuptools/command/bdist_egg.py +0 -456
  648. package/.venv/lib/python3.9/site-packages/setuptools/command/bdist_rpm.py +0 -40
  649. package/.venv/lib/python3.9/site-packages/setuptools/command/build_clib.py +0 -101
  650. package/.venv/lib/python3.9/site-packages/setuptools/command/build_ext.py +0 -328
  651. package/.venv/lib/python3.9/site-packages/setuptools/command/build_py.py +0 -242
  652. package/.venv/lib/python3.9/site-packages/setuptools/command/develop.py +0 -193
  653. package/.venv/lib/python3.9/site-packages/setuptools/command/dist_info.py +0 -36
  654. package/.venv/lib/python3.9/site-packages/setuptools/command/easy_install.py +0 -2304
  655. package/.venv/lib/python3.9/site-packages/setuptools/command/egg_info.py +0 -755
  656. package/.venv/lib/python3.9/site-packages/setuptools/command/install.py +0 -132
  657. package/.venv/lib/python3.9/site-packages/setuptools/command/install_egg_info.py +0 -62
  658. package/.venv/lib/python3.9/site-packages/setuptools/command/install_lib.py +0 -122
  659. package/.venv/lib/python3.9/site-packages/setuptools/command/install_scripts.py +0 -69
  660. package/.venv/lib/python3.9/site-packages/setuptools/command/launcher manifest.xml +0 -15
  661. package/.venv/lib/python3.9/site-packages/setuptools/command/py36compat.py +0 -134
  662. package/.venv/lib/python3.9/site-packages/setuptools/command/register.py +0 -18
  663. package/.venv/lib/python3.9/site-packages/setuptools/command/rotate.py +0 -64
  664. package/.venv/lib/python3.9/site-packages/setuptools/command/saveopts.py +0 -22
  665. package/.venv/lib/python3.9/site-packages/setuptools/command/sdist.py +0 -196
  666. package/.venv/lib/python3.9/site-packages/setuptools/command/setopt.py +0 -149
  667. package/.venv/lib/python3.9/site-packages/setuptools/command/test.py +0 -252
  668. package/.venv/lib/python3.9/site-packages/setuptools/command/upload.py +0 -17
  669. package/.venv/lib/python3.9/site-packages/setuptools/command/upload_docs.py +0 -202
  670. package/.venv/lib/python3.9/site-packages/setuptools/config.py +0 -751
  671. package/.venv/lib/python3.9/site-packages/setuptools/dep_util.py +0 -25
  672. package/.venv/lib/python3.9/site-packages/setuptools/depends.py +0 -176
  673. package/.venv/lib/python3.9/site-packages/setuptools/dist.py +0 -1156
  674. package/.venv/lib/python3.9/site-packages/setuptools/errors.py +0 -40
  675. package/.venv/lib/python3.9/site-packages/setuptools/extension.py +0 -55
  676. package/.venv/lib/python3.9/site-packages/setuptools/extern/__init__.py +0 -73
  677. package/.venv/lib/python3.9/site-packages/setuptools/glob.py +0 -167
  678. package/.venv/lib/python3.9/site-packages/setuptools/gui-32.exe +0 -0
  679. package/.venv/lib/python3.9/site-packages/setuptools/gui-64.exe +0 -0
  680. package/.venv/lib/python3.9/site-packages/setuptools/gui-arm64.exe +0 -0
  681. package/.venv/lib/python3.9/site-packages/setuptools/gui.exe +0 -0
  682. package/.venv/lib/python3.9/site-packages/setuptools/installer.py +0 -104
  683. package/.venv/lib/python3.9/site-packages/setuptools/launch.py +0 -36
  684. package/.venv/lib/python3.9/site-packages/setuptools/logging.py +0 -30
  685. package/.venv/lib/python3.9/site-packages/setuptools/monkey.py +0 -177
  686. package/.venv/lib/python3.9/site-packages/setuptools/msvc.py +0 -1805
  687. package/.venv/lib/python3.9/site-packages/setuptools/namespaces.py +0 -107
  688. package/.venv/lib/python3.9/site-packages/setuptools/package_index.py +0 -1127
  689. package/.venv/lib/python3.9/site-packages/setuptools/py34compat.py +0 -13
  690. package/.venv/lib/python3.9/site-packages/setuptools/sandbox.py +0 -530
  691. package/.venv/lib/python3.9/site-packages/setuptools/script (dev).tmpl +0 -6
  692. package/.venv/lib/python3.9/site-packages/setuptools/script.tmpl +0 -3
  693. package/.venv/lib/python3.9/site-packages/setuptools/tests/integration/__init__.py +0 -0
  694. package/.venv/lib/python3.9/site-packages/setuptools/tests/integration/helpers.py +0 -61
  695. package/.venv/lib/python3.9/site-packages/setuptools/tests/integration/test_pip_install_sdist.py +0 -218
  696. package/.venv/lib/python3.9/site-packages/setuptools/unicode_utils.py +0 -42
  697. package/.venv/lib/python3.9/site-packages/setuptools/version.py +0 -6
  698. package/.venv/lib/python3.9/site-packages/setuptools/wheel.py +0 -213
  699. package/.venv/lib/python3.9/site-packages/setuptools/windows_support.py +0 -29
  700. package/.venv/lib/python3.9/site-packages/setuptools-60.5.0.dist-info/INSTALLER +0 -1
  701. package/.venv/lib/python3.9/site-packages/setuptools-60.5.0.dist-info/LICENSE +0 -19
  702. package/.venv/lib/python3.9/site-packages/setuptools-60.5.0.dist-info/METADATA +0 -142
  703. package/.venv/lib/python3.9/site-packages/setuptools-60.5.0.dist-info/RECORD +0 -308
  704. package/.venv/lib/python3.9/site-packages/setuptools-60.5.0.dist-info/REQUESTED +0 -0
  705. package/.venv/lib/python3.9/site-packages/setuptools-60.5.0.dist-info/WHEEL +0 -5
  706. package/.venv/lib/python3.9/site-packages/setuptools-60.5.0.dist-info/entry_points.txt +0 -56
  707. package/.venv/lib/python3.9/site-packages/setuptools-60.5.0.dist-info/top_level.txt +0 -3
  708. package/.venv/pyvenv.cfg +0 -3
  709. package/.vscode/launch.json +0 -62
  710. package/.vscode/settings.json +0 -8
@@ -1,1969 +0,0 @@
1
- #
2
- # Copyright (C) 2012-2021 The Python Software Foundation.
3
- # See LICENSE.txt and CONTRIBUTORS.txt.
4
- #
5
- import codecs
6
- from collections import deque
7
- import contextlib
8
- import csv
9
- from glob import iglob as std_iglob
10
- import io
11
- import json
12
- import logging
13
- import os
14
- import py_compile
15
- import re
16
- import socket
17
- try:
18
- import ssl
19
- except ImportError: # pragma: no cover
20
- ssl = None
21
- import subprocess
22
- import sys
23
- import tarfile
24
- import tempfile
25
- import textwrap
26
-
27
- try:
28
- import threading
29
- except ImportError: # pragma: no cover
30
- import dummy_threading as threading
31
- import time
32
-
33
- from . import DistlibException
34
- from .compat import (string_types, text_type, shutil, raw_input, StringIO,
35
- cache_from_source, urlopen, urljoin, httplib, xmlrpclib,
36
- splittype, HTTPHandler, BaseConfigurator, valid_ident,
37
- Container, configparser, URLError, ZipFile, fsdecode,
38
- unquote, urlparse)
39
-
40
- logger = logging.getLogger(__name__)
41
-
42
- #
43
- # Requirement parsing code as per PEP 508
44
- #
45
-
46
- IDENTIFIER = re.compile(r'^([\w\.-]+)\s*')
47
- VERSION_IDENTIFIER = re.compile(r'^([\w\.*+-]+)\s*')
48
- COMPARE_OP = re.compile(r'^(<=?|>=?|={2,3}|[~!]=)\s*')
49
- MARKER_OP = re.compile(r'^((<=?)|(>=?)|={2,3}|[~!]=|in|not\s+in)\s*')
50
- OR = re.compile(r'^or\b\s*')
51
- AND = re.compile(r'^and\b\s*')
52
- NON_SPACE = re.compile(r'(\S+)\s*')
53
- STRING_CHUNK = re.compile(r'([\s\w\.{}()*+#:;,/?!~`@$%^&=|<>\[\]-]+)')
54
-
55
-
56
- def parse_marker(marker_string):
57
- """
58
- Parse a marker string and return a dictionary containing a marker expression.
59
-
60
- The dictionary will contain keys "op", "lhs" and "rhs" for non-terminals in
61
- the expression grammar, or strings. A string contained in quotes is to be
62
- interpreted as a literal string, and a string not contained in quotes is a
63
- variable (such as os_name).
64
- """
65
- def marker_var(remaining):
66
- # either identifier, or literal string
67
- m = IDENTIFIER.match(remaining)
68
- if m:
69
- result = m.groups()[0]
70
- remaining = remaining[m.end():]
71
- elif not remaining:
72
- raise SyntaxError('unexpected end of input')
73
- else:
74
- q = remaining[0]
75
- if q not in '\'"':
76
- raise SyntaxError('invalid expression: %s' % remaining)
77
- oq = '\'"'.replace(q, '')
78
- remaining = remaining[1:]
79
- parts = [q]
80
- while remaining:
81
- # either a string chunk, or oq, or q to terminate
82
- if remaining[0] == q:
83
- break
84
- elif remaining[0] == oq:
85
- parts.append(oq)
86
- remaining = remaining[1:]
87
- else:
88
- m = STRING_CHUNK.match(remaining)
89
- if not m:
90
- raise SyntaxError('error in string literal: %s' % remaining)
91
- parts.append(m.groups()[0])
92
- remaining = remaining[m.end():]
93
- else:
94
- s = ''.join(parts)
95
- raise SyntaxError('unterminated string: %s' % s)
96
- parts.append(q)
97
- result = ''.join(parts)
98
- remaining = remaining[1:].lstrip() # skip past closing quote
99
- return result, remaining
100
-
101
- def marker_expr(remaining):
102
- if remaining and remaining[0] == '(':
103
- result, remaining = marker(remaining[1:].lstrip())
104
- if remaining[0] != ')':
105
- raise SyntaxError('unterminated parenthesis: %s' % remaining)
106
- remaining = remaining[1:].lstrip()
107
- else:
108
- lhs, remaining = marker_var(remaining)
109
- while remaining:
110
- m = MARKER_OP.match(remaining)
111
- if not m:
112
- break
113
- op = m.groups()[0]
114
- remaining = remaining[m.end():]
115
- rhs, remaining = marker_var(remaining)
116
- lhs = {'op': op, 'lhs': lhs, 'rhs': rhs}
117
- result = lhs
118
- return result, remaining
119
-
120
- def marker_and(remaining):
121
- lhs, remaining = marker_expr(remaining)
122
- while remaining:
123
- m = AND.match(remaining)
124
- if not m:
125
- break
126
- remaining = remaining[m.end():]
127
- rhs, remaining = marker_expr(remaining)
128
- lhs = {'op': 'and', 'lhs': lhs, 'rhs': rhs}
129
- return lhs, remaining
130
-
131
- def marker(remaining):
132
- lhs, remaining = marker_and(remaining)
133
- while remaining:
134
- m = OR.match(remaining)
135
- if not m:
136
- break
137
- remaining = remaining[m.end():]
138
- rhs, remaining = marker_and(remaining)
139
- lhs = {'op': 'or', 'lhs': lhs, 'rhs': rhs}
140
- return lhs, remaining
141
-
142
- return marker(marker_string)
143
-
144
-
145
- def parse_requirement(req):
146
- """
147
- Parse a requirement passed in as a string. Return a Container
148
- whose attributes contain the various parts of the requirement.
149
- """
150
- remaining = req.strip()
151
- if not remaining or remaining.startswith('#'):
152
- return None
153
- m = IDENTIFIER.match(remaining)
154
- if not m:
155
- raise SyntaxError('name expected: %s' % remaining)
156
- distname = m.groups()[0]
157
- remaining = remaining[m.end():]
158
- extras = mark_expr = versions = uri = None
159
- if remaining and remaining[0] == '[':
160
- i = remaining.find(']', 1)
161
- if i < 0:
162
- raise SyntaxError('unterminated extra: %s' % remaining)
163
- s = remaining[1:i]
164
- remaining = remaining[i + 1:].lstrip()
165
- extras = []
166
- while s:
167
- m = IDENTIFIER.match(s)
168
- if not m:
169
- raise SyntaxError('malformed extra: %s' % s)
170
- extras.append(m.groups()[0])
171
- s = s[m.end():]
172
- if not s:
173
- break
174
- if s[0] != ',':
175
- raise SyntaxError('comma expected in extras: %s' % s)
176
- s = s[1:].lstrip()
177
- if not extras:
178
- extras = None
179
- if remaining:
180
- if remaining[0] == '@':
181
- # it's a URI
182
- remaining = remaining[1:].lstrip()
183
- m = NON_SPACE.match(remaining)
184
- if not m:
185
- raise SyntaxError('invalid URI: %s' % remaining)
186
- uri = m.groups()[0]
187
- t = urlparse(uri)
188
- # there are issues with Python and URL parsing, so this test
189
- # is a bit crude. See bpo-20271, bpo-23505. Python doesn't
190
- # always parse invalid URLs correctly - it should raise
191
- # exceptions for malformed URLs
192
- if not (t.scheme and t.netloc):
193
- raise SyntaxError('Invalid URL: %s' % uri)
194
- remaining = remaining[m.end():].lstrip()
195
- else:
196
-
197
- def get_versions(ver_remaining):
198
- """
199
- Return a list of operator, version tuples if any are
200
- specified, else None.
201
- """
202
- m = COMPARE_OP.match(ver_remaining)
203
- versions = None
204
- if m:
205
- versions = []
206
- while True:
207
- op = m.groups()[0]
208
- ver_remaining = ver_remaining[m.end():]
209
- m = VERSION_IDENTIFIER.match(ver_remaining)
210
- if not m:
211
- raise SyntaxError('invalid version: %s' % ver_remaining)
212
- v = m.groups()[0]
213
- versions.append((op, v))
214
- ver_remaining = ver_remaining[m.end():]
215
- if not ver_remaining or ver_remaining[0] != ',':
216
- break
217
- ver_remaining = ver_remaining[1:].lstrip()
218
- # Some packages have a trailing comma which would break things
219
- # See issue #148
220
- if not ver_remaining:
221
- break
222
- m = COMPARE_OP.match(ver_remaining)
223
- if not m:
224
- raise SyntaxError('invalid constraint: %s' % ver_remaining)
225
- if not versions:
226
- versions = None
227
- return versions, ver_remaining
228
-
229
- if remaining[0] != '(':
230
- versions, remaining = get_versions(remaining)
231
- else:
232
- i = remaining.find(')', 1)
233
- if i < 0:
234
- raise SyntaxError('unterminated parenthesis: %s' % remaining)
235
- s = remaining[1:i]
236
- remaining = remaining[i + 1:].lstrip()
237
- # As a special diversion from PEP 508, allow a version number
238
- # a.b.c in parentheses as a synonym for ~= a.b.c (because this
239
- # is allowed in earlier PEPs)
240
- if COMPARE_OP.match(s):
241
- versions, _ = get_versions(s)
242
- else:
243
- m = VERSION_IDENTIFIER.match(s)
244
- if not m:
245
- raise SyntaxError('invalid constraint: %s' % s)
246
- v = m.groups()[0]
247
- s = s[m.end():].lstrip()
248
- if s:
249
- raise SyntaxError('invalid constraint: %s' % s)
250
- versions = [('~=', v)]
251
-
252
- if remaining:
253
- if remaining[0] != ';':
254
- raise SyntaxError('invalid requirement: %s' % remaining)
255
- remaining = remaining[1:].lstrip()
256
-
257
- mark_expr, remaining = parse_marker(remaining)
258
-
259
- if remaining and remaining[0] != '#':
260
- raise SyntaxError('unexpected trailing data: %s' % remaining)
261
-
262
- if not versions:
263
- rs = distname
264
- else:
265
- rs = '%s %s' % (distname, ', '.join(['%s %s' % con for con in versions]))
266
- return Container(name=distname, extras=extras, constraints=versions,
267
- marker=mark_expr, url=uri, requirement=rs)
268
-
269
-
270
- def get_resources_dests(resources_root, rules):
271
- """Find destinations for resources files"""
272
-
273
- def get_rel_path(root, path):
274
- # normalizes and returns a lstripped-/-separated path
275
- root = root.replace(os.path.sep, '/')
276
- path = path.replace(os.path.sep, '/')
277
- assert path.startswith(root)
278
- return path[len(root):].lstrip('/')
279
-
280
- destinations = {}
281
- for base, suffix, dest in rules:
282
- prefix = os.path.join(resources_root, base)
283
- for abs_base in iglob(prefix):
284
- abs_glob = os.path.join(abs_base, suffix)
285
- for abs_path in iglob(abs_glob):
286
- resource_file = get_rel_path(resources_root, abs_path)
287
- if dest is None: # remove the entry if it was here
288
- destinations.pop(resource_file, None)
289
- else:
290
- rel_path = get_rel_path(abs_base, abs_path)
291
- rel_dest = dest.replace(os.path.sep, '/').rstrip('/')
292
- destinations[resource_file] = rel_dest + '/' + rel_path
293
- return destinations
294
-
295
-
296
- def in_venv():
297
- if hasattr(sys, 'real_prefix'):
298
- # virtualenv venvs
299
- result = True
300
- else:
301
- # PEP 405 venvs
302
- result = sys.prefix != getattr(sys, 'base_prefix', sys.prefix)
303
- return result
304
-
305
-
306
- def get_executable():
307
- # The __PYVENV_LAUNCHER__ dance is apparently no longer needed, as
308
- # changes to the stub launcher mean that sys.executable always points
309
- # to the stub on OS X
310
- # if sys.platform == 'darwin' and ('__PYVENV_LAUNCHER__'
311
- # in os.environ):
312
- # result = os.environ['__PYVENV_LAUNCHER__']
313
- # else:
314
- # result = sys.executable
315
- # return result
316
- # Avoid normcasing: see issue #143
317
- # result = os.path.normcase(sys.executable)
318
- result = sys.executable
319
- if not isinstance(result, text_type):
320
- result = fsdecode(result)
321
- return result
322
-
323
-
324
- def proceed(prompt, allowed_chars, error_prompt=None, default=None):
325
- p = prompt
326
- while True:
327
- s = raw_input(p)
328
- p = prompt
329
- if not s and default:
330
- s = default
331
- if s:
332
- c = s[0].lower()
333
- if c in allowed_chars:
334
- break
335
- if error_prompt:
336
- p = '%c: %s\n%s' % (c, error_prompt, prompt)
337
- return c
338
-
339
-
340
- def extract_by_key(d, keys):
341
- if isinstance(keys, string_types):
342
- keys = keys.split()
343
- result = {}
344
- for key in keys:
345
- if key in d:
346
- result[key] = d[key]
347
- return result
348
-
349
- def read_exports(stream):
350
- if sys.version_info[0] >= 3:
351
- # needs to be a text stream
352
- stream = codecs.getreader('utf-8')(stream)
353
- # Try to load as JSON, falling back on legacy format
354
- data = stream.read()
355
- stream = StringIO(data)
356
- try:
357
- jdata = json.load(stream)
358
- result = jdata['extensions']['python.exports']['exports']
359
- for group, entries in result.items():
360
- for k, v in entries.items():
361
- s = '%s = %s' % (k, v)
362
- entry = get_export_entry(s)
363
- assert entry is not None
364
- entries[k] = entry
365
- return result
366
- except Exception:
367
- stream.seek(0, 0)
368
-
369
- def read_stream(cp, stream):
370
- if hasattr(cp, 'read_file'):
371
- cp.read_file(stream)
372
- else:
373
- cp.readfp(stream)
374
-
375
- cp = configparser.ConfigParser()
376
- try:
377
- read_stream(cp, stream)
378
- except configparser.MissingSectionHeaderError:
379
- stream.close()
380
- data = textwrap.dedent(data)
381
- stream = StringIO(data)
382
- read_stream(cp, stream)
383
-
384
- result = {}
385
- for key in cp.sections():
386
- result[key] = entries = {}
387
- for name, value in cp.items(key):
388
- s = '%s = %s' % (name, value)
389
- entry = get_export_entry(s)
390
- assert entry is not None
391
- #entry.dist = self
392
- entries[name] = entry
393
- return result
394
-
395
-
396
- def write_exports(exports, stream):
397
- if sys.version_info[0] >= 3:
398
- # needs to be a text stream
399
- stream = codecs.getwriter('utf-8')(stream)
400
- cp = configparser.ConfigParser()
401
- for k, v in exports.items():
402
- # TODO check k, v for valid values
403
- cp.add_section(k)
404
- for entry in v.values():
405
- if entry.suffix is None:
406
- s = entry.prefix
407
- else:
408
- s = '%s:%s' % (entry.prefix, entry.suffix)
409
- if entry.flags:
410
- s = '%s [%s]' % (s, ', '.join(entry.flags))
411
- cp.set(k, entry.name, s)
412
- cp.write(stream)
413
-
414
-
415
- @contextlib.contextmanager
416
- def tempdir():
417
- td = tempfile.mkdtemp()
418
- try:
419
- yield td
420
- finally:
421
- shutil.rmtree(td)
422
-
423
- @contextlib.contextmanager
424
- def chdir(d):
425
- cwd = os.getcwd()
426
- try:
427
- os.chdir(d)
428
- yield
429
- finally:
430
- os.chdir(cwd)
431
-
432
-
433
- @contextlib.contextmanager
434
- def socket_timeout(seconds=15):
435
- cto = socket.getdefaulttimeout()
436
- try:
437
- socket.setdefaulttimeout(seconds)
438
- yield
439
- finally:
440
- socket.setdefaulttimeout(cto)
441
-
442
-
443
- class cached_property(object):
444
- def __init__(self, func):
445
- self.func = func
446
- #for attr in ('__name__', '__module__', '__doc__'):
447
- # setattr(self, attr, getattr(func, attr, None))
448
-
449
- def __get__(self, obj, cls=None):
450
- if obj is None:
451
- return self
452
- value = self.func(obj)
453
- object.__setattr__(obj, self.func.__name__, value)
454
- #obj.__dict__[self.func.__name__] = value = self.func(obj)
455
- return value
456
-
457
- def convert_path(pathname):
458
- """Return 'pathname' as a name that will work on the native filesystem.
459
-
460
- The path is split on '/' and put back together again using the current
461
- directory separator. Needed because filenames in the setup script are
462
- always supplied in Unix style, and have to be converted to the local
463
- convention before we can actually use them in the filesystem. Raises
464
- ValueError on non-Unix-ish systems if 'pathname' either starts or
465
- ends with a slash.
466
- """
467
- if os.sep == '/':
468
- return pathname
469
- if not pathname:
470
- return pathname
471
- if pathname[0] == '/':
472
- raise ValueError("path '%s' cannot be absolute" % pathname)
473
- if pathname[-1] == '/':
474
- raise ValueError("path '%s' cannot end with '/'" % pathname)
475
-
476
- paths = pathname.split('/')
477
- while os.curdir in paths:
478
- paths.remove(os.curdir)
479
- if not paths:
480
- return os.curdir
481
- return os.path.join(*paths)
482
-
483
-
484
- class FileOperator(object):
485
- def __init__(self, dry_run=False):
486
- self.dry_run = dry_run
487
- self.ensured = set()
488
- self._init_record()
489
-
490
- def _init_record(self):
491
- self.record = False
492
- self.files_written = set()
493
- self.dirs_created = set()
494
-
495
- def record_as_written(self, path):
496
- if self.record:
497
- self.files_written.add(path)
498
-
499
- def newer(self, source, target):
500
- """Tell if the target is newer than the source.
501
-
502
- Returns true if 'source' exists and is more recently modified than
503
- 'target', or if 'source' exists and 'target' doesn't.
504
-
505
- Returns false if both exist and 'target' is the same age or younger
506
- than 'source'. Raise PackagingFileError if 'source' does not exist.
507
-
508
- Note that this test is not very accurate: files created in the same
509
- second will have the same "age".
510
- """
511
- if not os.path.exists(source):
512
- raise DistlibException("file '%r' does not exist" %
513
- os.path.abspath(source))
514
- if not os.path.exists(target):
515
- return True
516
-
517
- return os.stat(source).st_mtime > os.stat(target).st_mtime
518
-
519
- def copy_file(self, infile, outfile, check=True):
520
- """Copy a file respecting dry-run and force flags.
521
- """
522
- self.ensure_dir(os.path.dirname(outfile))
523
- logger.info('Copying %s to %s', infile, outfile)
524
- if not self.dry_run:
525
- msg = None
526
- if check:
527
- if os.path.islink(outfile):
528
- msg = '%s is a symlink' % outfile
529
- elif os.path.exists(outfile) and not os.path.isfile(outfile):
530
- msg = '%s is a non-regular file' % outfile
531
- if msg:
532
- raise ValueError(msg + ' which would be overwritten')
533
- shutil.copyfile(infile, outfile)
534
- self.record_as_written(outfile)
535
-
536
- def copy_stream(self, instream, outfile, encoding=None):
537
- assert not os.path.isdir(outfile)
538
- self.ensure_dir(os.path.dirname(outfile))
539
- logger.info('Copying stream %s to %s', instream, outfile)
540
- if not self.dry_run:
541
- if encoding is None:
542
- outstream = open(outfile, 'wb')
543
- else:
544
- outstream = codecs.open(outfile, 'w', encoding=encoding)
545
- try:
546
- shutil.copyfileobj(instream, outstream)
547
- finally:
548
- outstream.close()
549
- self.record_as_written(outfile)
550
-
551
- def write_binary_file(self, path, data):
552
- self.ensure_dir(os.path.dirname(path))
553
- if not self.dry_run:
554
- if os.path.exists(path):
555
- os.remove(path)
556
- with open(path, 'wb') as f:
557
- f.write(data)
558
- self.record_as_written(path)
559
-
560
- def write_text_file(self, path, data, encoding):
561
- self.write_binary_file(path, data.encode(encoding))
562
-
563
- def set_mode(self, bits, mask, files):
564
- if os.name == 'posix' or (os.name == 'java' and os._name == 'posix'):
565
- # Set the executable bits (owner, group, and world) on
566
- # all the files specified.
567
- for f in files:
568
- if self.dry_run:
569
- logger.info("changing mode of %s", f)
570
- else:
571
- mode = (os.stat(f).st_mode | bits) & mask
572
- logger.info("changing mode of %s to %o", f, mode)
573
- os.chmod(f, mode)
574
-
575
- set_executable_mode = lambda s, f: s.set_mode(0o555, 0o7777, f)
576
-
577
- def ensure_dir(self, path):
578
- path = os.path.abspath(path)
579
- if path not in self.ensured and not os.path.exists(path):
580
- self.ensured.add(path)
581
- d, f = os.path.split(path)
582
- self.ensure_dir(d)
583
- logger.info('Creating %s' % path)
584
- if not self.dry_run:
585
- os.mkdir(path)
586
- if self.record:
587
- self.dirs_created.add(path)
588
-
589
- def byte_compile(self, path, optimize=False, force=False, prefix=None, hashed_invalidation=False):
590
- dpath = cache_from_source(path, not optimize)
591
- logger.info('Byte-compiling %s to %s', path, dpath)
592
- if not self.dry_run:
593
- if force or self.newer(path, dpath):
594
- if not prefix:
595
- diagpath = None
596
- else:
597
- assert path.startswith(prefix)
598
- diagpath = path[len(prefix):]
599
- compile_kwargs = {}
600
- if hashed_invalidation and hasattr(py_compile, 'PycInvalidationMode'):
601
- compile_kwargs['invalidation_mode'] = py_compile.PycInvalidationMode.CHECKED_HASH
602
- py_compile.compile(path, dpath, diagpath, True, **compile_kwargs) # raise error
603
- self.record_as_written(dpath)
604
- return dpath
605
-
606
- def ensure_removed(self, path):
607
- if os.path.exists(path):
608
- if os.path.isdir(path) and not os.path.islink(path):
609
- logger.debug('Removing directory tree at %s', path)
610
- if not self.dry_run:
611
- shutil.rmtree(path)
612
- if self.record:
613
- if path in self.dirs_created:
614
- self.dirs_created.remove(path)
615
- else:
616
- if os.path.islink(path):
617
- s = 'link'
618
- else:
619
- s = 'file'
620
- logger.debug('Removing %s %s', s, path)
621
- if not self.dry_run:
622
- os.remove(path)
623
- if self.record:
624
- if path in self.files_written:
625
- self.files_written.remove(path)
626
-
627
- def is_writable(self, path):
628
- result = False
629
- while not result:
630
- if os.path.exists(path):
631
- result = os.access(path, os.W_OK)
632
- break
633
- parent = os.path.dirname(path)
634
- if parent == path:
635
- break
636
- path = parent
637
- return result
638
-
639
- def commit(self):
640
- """
641
- Commit recorded changes, turn off recording, return
642
- changes.
643
- """
644
- assert self.record
645
- result = self.files_written, self.dirs_created
646
- self._init_record()
647
- return result
648
-
649
- def rollback(self):
650
- if not self.dry_run:
651
- for f in list(self.files_written):
652
- if os.path.exists(f):
653
- os.remove(f)
654
- # dirs should all be empty now, except perhaps for
655
- # __pycache__ subdirs
656
- # reverse so that subdirs appear before their parents
657
- dirs = sorted(self.dirs_created, reverse=True)
658
- for d in dirs:
659
- flist = os.listdir(d)
660
- if flist:
661
- assert flist == ['__pycache__']
662
- sd = os.path.join(d, flist[0])
663
- os.rmdir(sd)
664
- os.rmdir(d) # should fail if non-empty
665
- self._init_record()
666
-
667
- def resolve(module_name, dotted_path):
668
- if module_name in sys.modules:
669
- mod = sys.modules[module_name]
670
- else:
671
- mod = __import__(module_name)
672
- if dotted_path is None:
673
- result = mod
674
- else:
675
- parts = dotted_path.split('.')
676
- result = getattr(mod, parts.pop(0))
677
- for p in parts:
678
- result = getattr(result, p)
679
- return result
680
-
681
-
682
- class ExportEntry(object):
683
- def __init__(self, name, prefix, suffix, flags):
684
- self.name = name
685
- self.prefix = prefix
686
- self.suffix = suffix
687
- self.flags = flags
688
-
689
- @cached_property
690
- def value(self):
691
- return resolve(self.prefix, self.suffix)
692
-
693
- def __repr__(self): # pragma: no cover
694
- return '<ExportEntry %s = %s:%s %s>' % (self.name, self.prefix,
695
- self.suffix, self.flags)
696
-
697
- def __eq__(self, other):
698
- if not isinstance(other, ExportEntry):
699
- result = False
700
- else:
701
- result = (self.name == other.name and
702
- self.prefix == other.prefix and
703
- self.suffix == other.suffix and
704
- self.flags == other.flags)
705
- return result
706
-
707
- __hash__ = object.__hash__
708
-
709
-
710
- ENTRY_RE = re.compile(r'''(?P<name>(\w|[-.+])+)
711
- \s*=\s*(?P<callable>(\w+)([:\.]\w+)*)
712
- \s*(\[\s*(?P<flags>[\w-]+(=\w+)?(,\s*\w+(=\w+)?)*)\s*\])?
713
- ''', re.VERBOSE)
714
-
715
- def get_export_entry(specification):
716
- m = ENTRY_RE.search(specification)
717
- if not m:
718
- result = None
719
- if '[' in specification or ']' in specification:
720
- raise DistlibException("Invalid specification "
721
- "'%s'" % specification)
722
- else:
723
- d = m.groupdict()
724
- name = d['name']
725
- path = d['callable']
726
- colons = path.count(':')
727
- if colons == 0:
728
- prefix, suffix = path, None
729
- else:
730
- if colons != 1:
731
- raise DistlibException("Invalid specification "
732
- "'%s'" % specification)
733
- prefix, suffix = path.split(':')
734
- flags = d['flags']
735
- if flags is None:
736
- if '[' in specification or ']' in specification:
737
- raise DistlibException("Invalid specification "
738
- "'%s'" % specification)
739
- flags = []
740
- else:
741
- flags = [f.strip() for f in flags.split(',')]
742
- result = ExportEntry(name, prefix, suffix, flags)
743
- return result
744
-
745
-
746
- def get_cache_base(suffix=None):
747
- """
748
- Return the default base location for distlib caches. If the directory does
749
- not exist, it is created. Use the suffix provided for the base directory,
750
- and default to '.distlib' if it isn't provided.
751
-
752
- On Windows, if LOCALAPPDATA is defined in the environment, then it is
753
- assumed to be a directory, and will be the parent directory of the result.
754
- On POSIX, and on Windows if LOCALAPPDATA is not defined, the user's home
755
- directory - using os.expanduser('~') - will be the parent directory of
756
- the result.
757
-
758
- The result is just the directory '.distlib' in the parent directory as
759
- determined above, or with the name specified with ``suffix``.
760
- """
761
- if suffix is None:
762
- suffix = '.distlib'
763
- if os.name == 'nt' and 'LOCALAPPDATA' in os.environ:
764
- result = os.path.expandvars('$localappdata')
765
- else:
766
- # Assume posix, or old Windows
767
- result = os.path.expanduser('~')
768
- # we use 'isdir' instead of 'exists', because we want to
769
- # fail if there's a file with that name
770
- if os.path.isdir(result):
771
- usable = os.access(result, os.W_OK)
772
- if not usable:
773
- logger.warning('Directory exists but is not writable: %s', result)
774
- else:
775
- try:
776
- os.makedirs(result)
777
- usable = True
778
- except OSError:
779
- logger.warning('Unable to create %s', result, exc_info=True)
780
- usable = False
781
- if not usable:
782
- result = tempfile.mkdtemp()
783
- logger.warning('Default location unusable, using %s', result)
784
- return os.path.join(result, suffix)
785
-
786
-
787
- def path_to_cache_dir(path):
788
- """
789
- Convert an absolute path to a directory name for use in a cache.
790
-
791
- The algorithm used is:
792
-
793
- #. On Windows, any ``':'`` in the drive is replaced with ``'---'``.
794
- #. Any occurrence of ``os.sep`` is replaced with ``'--'``.
795
- #. ``'.cache'`` is appended.
796
- """
797
- d, p = os.path.splitdrive(os.path.abspath(path))
798
- if d:
799
- d = d.replace(':', '---')
800
- p = p.replace(os.sep, '--')
801
- return d + p + '.cache'
802
-
803
-
804
- def ensure_slash(s):
805
- if not s.endswith('/'):
806
- return s + '/'
807
- return s
808
-
809
-
810
- def parse_credentials(netloc):
811
- username = password = None
812
- if '@' in netloc:
813
- prefix, netloc = netloc.rsplit('@', 1)
814
- if ':' not in prefix:
815
- username = prefix
816
- else:
817
- username, password = prefix.split(':', 1)
818
- if username:
819
- username = unquote(username)
820
- if password:
821
- password = unquote(password)
822
- return username, password, netloc
823
-
824
-
825
- def get_process_umask():
826
- result = os.umask(0o22)
827
- os.umask(result)
828
- return result
829
-
830
- def is_string_sequence(seq):
831
- result = True
832
- i = None
833
- for i, s in enumerate(seq):
834
- if not isinstance(s, string_types):
835
- result = False
836
- break
837
- assert i is not None
838
- return result
839
-
840
- PROJECT_NAME_AND_VERSION = re.compile('([a-z0-9_]+([.-][a-z_][a-z0-9_]*)*)-'
841
- '([a-z0-9_.+-]+)', re.I)
842
- PYTHON_VERSION = re.compile(r'-py(\d\.?\d?)')
843
-
844
-
845
- def split_filename(filename, project_name=None):
846
- """
847
- Extract name, version, python version from a filename (no extension)
848
-
849
- Return name, version, pyver or None
850
- """
851
- result = None
852
- pyver = None
853
- filename = unquote(filename).replace(' ', '-')
854
- m = PYTHON_VERSION.search(filename)
855
- if m:
856
- pyver = m.group(1)
857
- filename = filename[:m.start()]
858
- if project_name and len(filename) > len(project_name) + 1:
859
- m = re.match(re.escape(project_name) + r'\b', filename)
860
- if m:
861
- n = m.end()
862
- result = filename[:n], filename[n + 1:], pyver
863
- if result is None:
864
- m = PROJECT_NAME_AND_VERSION.match(filename)
865
- if m:
866
- result = m.group(1), m.group(3), pyver
867
- return result
868
-
869
- # Allow spaces in name because of legacy dists like "Twisted Core"
870
- NAME_VERSION_RE = re.compile(r'(?P<name>[\w .-]+)\s*'
871
- r'\(\s*(?P<ver>[^\s)]+)\)$')
872
-
873
- def parse_name_and_version(p):
874
- """
875
- A utility method used to get name and version from a string.
876
-
877
- From e.g. a Provides-Dist value.
878
-
879
- :param p: A value in a form 'foo (1.0)'
880
- :return: The name and version as a tuple.
881
- """
882
- m = NAME_VERSION_RE.match(p)
883
- if not m:
884
- raise DistlibException('Ill-formed name/version string: \'%s\'' % p)
885
- d = m.groupdict()
886
- return d['name'].strip().lower(), d['ver']
887
-
888
- def get_extras(requested, available):
889
- result = set()
890
- requested = set(requested or [])
891
- available = set(available or [])
892
- if '*' in requested:
893
- requested.remove('*')
894
- result |= available
895
- for r in requested:
896
- if r == '-':
897
- result.add(r)
898
- elif r.startswith('-'):
899
- unwanted = r[1:]
900
- if unwanted not in available:
901
- logger.warning('undeclared extra: %s' % unwanted)
902
- if unwanted in result:
903
- result.remove(unwanted)
904
- else:
905
- if r not in available:
906
- logger.warning('undeclared extra: %s' % r)
907
- result.add(r)
908
- return result
909
- #
910
- # Extended metadata functionality
911
- #
912
-
913
- def _get_external_data(url):
914
- result = {}
915
- try:
916
- # urlopen might fail if it runs into redirections,
917
- # because of Python issue #13696. Fixed in locators
918
- # using a custom redirect handler.
919
- resp = urlopen(url)
920
- headers = resp.info()
921
- ct = headers.get('Content-Type')
922
- if not ct.startswith('application/json'):
923
- logger.debug('Unexpected response for JSON request: %s', ct)
924
- else:
925
- reader = codecs.getreader('utf-8')(resp)
926
- #data = reader.read().decode('utf-8')
927
- #result = json.loads(data)
928
- result = json.load(reader)
929
- except Exception as e:
930
- logger.exception('Failed to get external data for %s: %s', url, e)
931
- return result
932
-
933
- _external_data_base_url = 'https://www.red-dove.com/pypi/projects/'
934
-
935
- def get_project_data(name):
936
- url = '%s/%s/project.json' % (name[0].upper(), name)
937
- url = urljoin(_external_data_base_url, url)
938
- result = _get_external_data(url)
939
- return result
940
-
941
- def get_package_data(name, version):
942
- url = '%s/%s/package-%s.json' % (name[0].upper(), name, version)
943
- url = urljoin(_external_data_base_url, url)
944
- return _get_external_data(url)
945
-
946
-
947
- class Cache(object):
948
- """
949
- A class implementing a cache for resources that need to live in the file system
950
- e.g. shared libraries. This class was moved from resources to here because it
951
- could be used by other modules, e.g. the wheel module.
952
- """
953
-
954
- def __init__(self, base):
955
- """
956
- Initialise an instance.
957
-
958
- :param base: The base directory where the cache should be located.
959
- """
960
- # we use 'isdir' instead of 'exists', because we want to
961
- # fail if there's a file with that name
962
- if not os.path.isdir(base): # pragma: no cover
963
- os.makedirs(base)
964
- if (os.stat(base).st_mode & 0o77) != 0:
965
- logger.warning('Directory \'%s\' is not private', base)
966
- self.base = os.path.abspath(os.path.normpath(base))
967
-
968
- def prefix_to_dir(self, prefix):
969
- """
970
- Converts a resource prefix to a directory name in the cache.
971
- """
972
- return path_to_cache_dir(prefix)
973
-
974
- def clear(self):
975
- """
976
- Clear the cache.
977
- """
978
- not_removed = []
979
- for fn in os.listdir(self.base):
980
- fn = os.path.join(self.base, fn)
981
- try:
982
- if os.path.islink(fn) or os.path.isfile(fn):
983
- os.remove(fn)
984
- elif os.path.isdir(fn):
985
- shutil.rmtree(fn)
986
- except Exception:
987
- not_removed.append(fn)
988
- return not_removed
989
-
990
-
991
- class EventMixin(object):
992
- """
993
- A very simple publish/subscribe system.
994
- """
995
- def __init__(self):
996
- self._subscribers = {}
997
-
998
- def add(self, event, subscriber, append=True):
999
- """
1000
- Add a subscriber for an event.
1001
-
1002
- :param event: The name of an event.
1003
- :param subscriber: The subscriber to be added (and called when the
1004
- event is published).
1005
- :param append: Whether to append or prepend the subscriber to an
1006
- existing subscriber list for the event.
1007
- """
1008
- subs = self._subscribers
1009
- if event not in subs:
1010
- subs[event] = deque([subscriber])
1011
- else:
1012
- sq = subs[event]
1013
- if append:
1014
- sq.append(subscriber)
1015
- else:
1016
- sq.appendleft(subscriber)
1017
-
1018
- def remove(self, event, subscriber):
1019
- """
1020
- Remove a subscriber for an event.
1021
-
1022
- :param event: The name of an event.
1023
- :param subscriber: The subscriber to be removed.
1024
- """
1025
- subs = self._subscribers
1026
- if event not in subs:
1027
- raise ValueError('No subscribers: %r' % event)
1028
- subs[event].remove(subscriber)
1029
-
1030
- def get_subscribers(self, event):
1031
- """
1032
- Return an iterator for the subscribers for an event.
1033
- :param event: The event to return subscribers for.
1034
- """
1035
- return iter(self._subscribers.get(event, ()))
1036
-
1037
- def publish(self, event, *args, **kwargs):
1038
- """
1039
- Publish a event and return a list of values returned by its
1040
- subscribers.
1041
-
1042
- :param event: The event to publish.
1043
- :param args: The positional arguments to pass to the event's
1044
- subscribers.
1045
- :param kwargs: The keyword arguments to pass to the event's
1046
- subscribers.
1047
- """
1048
- result = []
1049
- for subscriber in self.get_subscribers(event):
1050
- try:
1051
- value = subscriber(event, *args, **kwargs)
1052
- except Exception:
1053
- logger.exception('Exception during event publication')
1054
- value = None
1055
- result.append(value)
1056
- logger.debug('publish %s: args = %s, kwargs = %s, result = %s',
1057
- event, args, kwargs, result)
1058
- return result
1059
-
1060
- #
1061
- # Simple sequencing
1062
- #
1063
- class Sequencer(object):
1064
- def __init__(self):
1065
- self._preds = {}
1066
- self._succs = {}
1067
- self._nodes = set() # nodes with no preds/succs
1068
-
1069
- def add_node(self, node):
1070
- self._nodes.add(node)
1071
-
1072
- def remove_node(self, node, edges=False):
1073
- if node in self._nodes:
1074
- self._nodes.remove(node)
1075
- if edges:
1076
- for p in set(self._preds.get(node, ())):
1077
- self.remove(p, node)
1078
- for s in set(self._succs.get(node, ())):
1079
- self.remove(node, s)
1080
- # Remove empties
1081
- for k, v in list(self._preds.items()):
1082
- if not v:
1083
- del self._preds[k]
1084
- for k, v in list(self._succs.items()):
1085
- if not v:
1086
- del self._succs[k]
1087
-
1088
- def add(self, pred, succ):
1089
- assert pred != succ
1090
- self._preds.setdefault(succ, set()).add(pred)
1091
- self._succs.setdefault(pred, set()).add(succ)
1092
-
1093
- def remove(self, pred, succ):
1094
- assert pred != succ
1095
- try:
1096
- preds = self._preds[succ]
1097
- succs = self._succs[pred]
1098
- except KeyError: # pragma: no cover
1099
- raise ValueError('%r not a successor of anything' % succ)
1100
- try:
1101
- preds.remove(pred)
1102
- succs.remove(succ)
1103
- except KeyError: # pragma: no cover
1104
- raise ValueError('%r not a successor of %r' % (succ, pred))
1105
-
1106
- def is_step(self, step):
1107
- return (step in self._preds or step in self._succs or
1108
- step in self._nodes)
1109
-
1110
- def get_steps(self, final):
1111
- if not self.is_step(final):
1112
- raise ValueError('Unknown: %r' % final)
1113
- result = []
1114
- todo = []
1115
- seen = set()
1116
- todo.append(final)
1117
- while todo:
1118
- step = todo.pop(0)
1119
- if step in seen:
1120
- # if a step was already seen,
1121
- # move it to the end (so it will appear earlier
1122
- # when reversed on return) ... but not for the
1123
- # final step, as that would be confusing for
1124
- # users
1125
- if step != final:
1126
- result.remove(step)
1127
- result.append(step)
1128
- else:
1129
- seen.add(step)
1130
- result.append(step)
1131
- preds = self._preds.get(step, ())
1132
- todo.extend(preds)
1133
- return reversed(result)
1134
-
1135
- @property
1136
- def strong_connections(self):
1137
- #http://en.wikipedia.org/wiki/Tarjan%27s_strongly_connected_components_algorithm
1138
- index_counter = [0]
1139
- stack = []
1140
- lowlinks = {}
1141
- index = {}
1142
- result = []
1143
-
1144
- graph = self._succs
1145
-
1146
- def strongconnect(node):
1147
- # set the depth index for this node to the smallest unused index
1148
- index[node] = index_counter[0]
1149
- lowlinks[node] = index_counter[0]
1150
- index_counter[0] += 1
1151
- stack.append(node)
1152
-
1153
- # Consider successors
1154
- try:
1155
- successors = graph[node]
1156
- except Exception:
1157
- successors = []
1158
- for successor in successors:
1159
- if successor not in lowlinks:
1160
- # Successor has not yet been visited
1161
- strongconnect(successor)
1162
- lowlinks[node] = min(lowlinks[node],lowlinks[successor])
1163
- elif successor in stack:
1164
- # the successor is in the stack and hence in the current
1165
- # strongly connected component (SCC)
1166
- lowlinks[node] = min(lowlinks[node],index[successor])
1167
-
1168
- # If `node` is a root node, pop the stack and generate an SCC
1169
- if lowlinks[node] == index[node]:
1170
- connected_component = []
1171
-
1172
- while True:
1173
- successor = stack.pop()
1174
- connected_component.append(successor)
1175
- if successor == node: break
1176
- component = tuple(connected_component)
1177
- # storing the result
1178
- result.append(component)
1179
-
1180
- for node in graph:
1181
- if node not in lowlinks:
1182
- strongconnect(node)
1183
-
1184
- return result
1185
-
1186
- @property
1187
- def dot(self):
1188
- result = ['digraph G {']
1189
- for succ in self._preds:
1190
- preds = self._preds[succ]
1191
- for pred in preds:
1192
- result.append(' %s -> %s;' % (pred, succ))
1193
- for node in self._nodes:
1194
- result.append(' %s;' % node)
1195
- result.append('}')
1196
- return '\n'.join(result)
1197
-
1198
- #
1199
- # Unarchiving functionality for zip, tar, tgz, tbz, whl
1200
- #
1201
-
1202
- ARCHIVE_EXTENSIONS = ('.tar.gz', '.tar.bz2', '.tar', '.zip',
1203
- '.tgz', '.tbz', '.whl')
1204
-
1205
- def unarchive(archive_filename, dest_dir, format=None, check=True):
1206
-
1207
- def check_path(path):
1208
- if not isinstance(path, text_type):
1209
- path = path.decode('utf-8')
1210
- p = os.path.abspath(os.path.join(dest_dir, path))
1211
- if not p.startswith(dest_dir) or p[plen] != os.sep:
1212
- raise ValueError('path outside destination: %r' % p)
1213
-
1214
- dest_dir = os.path.abspath(dest_dir)
1215
- plen = len(dest_dir)
1216
- archive = None
1217
- if format is None:
1218
- if archive_filename.endswith(('.zip', '.whl')):
1219
- format = 'zip'
1220
- elif archive_filename.endswith(('.tar.gz', '.tgz')):
1221
- format = 'tgz'
1222
- mode = 'r:gz'
1223
- elif archive_filename.endswith(('.tar.bz2', '.tbz')):
1224
- format = 'tbz'
1225
- mode = 'r:bz2'
1226
- elif archive_filename.endswith('.tar'):
1227
- format = 'tar'
1228
- mode = 'r'
1229
- else: # pragma: no cover
1230
- raise ValueError('Unknown format for %r' % archive_filename)
1231
- try:
1232
- if format == 'zip':
1233
- archive = ZipFile(archive_filename, 'r')
1234
- if check:
1235
- names = archive.namelist()
1236
- for name in names:
1237
- check_path(name)
1238
- else:
1239
- archive = tarfile.open(archive_filename, mode)
1240
- if check:
1241
- names = archive.getnames()
1242
- for name in names:
1243
- check_path(name)
1244
- if format != 'zip' and sys.version_info[0] < 3:
1245
- # See Python issue 17153. If the dest path contains Unicode,
1246
- # tarfile extraction fails on Python 2.x if a member path name
1247
- # contains non-ASCII characters - it leads to an implicit
1248
- # bytes -> unicode conversion using ASCII to decode.
1249
- for tarinfo in archive.getmembers():
1250
- if not isinstance(tarinfo.name, text_type):
1251
- tarinfo.name = tarinfo.name.decode('utf-8')
1252
- archive.extractall(dest_dir)
1253
-
1254
- finally:
1255
- if archive:
1256
- archive.close()
1257
-
1258
-
1259
- def zip_dir(directory):
1260
- """zip a directory tree into a BytesIO object"""
1261
- result = io.BytesIO()
1262
- dlen = len(directory)
1263
- with ZipFile(result, "w") as zf:
1264
- for root, dirs, files in os.walk(directory):
1265
- for name in files:
1266
- full = os.path.join(root, name)
1267
- rel = root[dlen:]
1268
- dest = os.path.join(rel, name)
1269
- zf.write(full, dest)
1270
- return result
1271
-
1272
- #
1273
- # Simple progress bar
1274
- #
1275
-
1276
- UNITS = ('', 'K', 'M', 'G','T','P')
1277
-
1278
-
1279
- class Progress(object):
1280
- unknown = 'UNKNOWN'
1281
-
1282
- def __init__(self, minval=0, maxval=100):
1283
- assert maxval is None or maxval >= minval
1284
- self.min = self.cur = minval
1285
- self.max = maxval
1286
- self.started = None
1287
- self.elapsed = 0
1288
- self.done = False
1289
-
1290
- def update(self, curval):
1291
- assert self.min <= curval
1292
- assert self.max is None or curval <= self.max
1293
- self.cur = curval
1294
- now = time.time()
1295
- if self.started is None:
1296
- self.started = now
1297
- else:
1298
- self.elapsed = now - self.started
1299
-
1300
- def increment(self, incr):
1301
- assert incr >= 0
1302
- self.update(self.cur + incr)
1303
-
1304
- def start(self):
1305
- self.update(self.min)
1306
- return self
1307
-
1308
- def stop(self):
1309
- if self.max is not None:
1310
- self.update(self.max)
1311
- self.done = True
1312
-
1313
- @property
1314
- def maximum(self):
1315
- return self.unknown if self.max is None else self.max
1316
-
1317
- @property
1318
- def percentage(self):
1319
- if self.done:
1320
- result = '100 %'
1321
- elif self.max is None:
1322
- result = ' ?? %'
1323
- else:
1324
- v = 100.0 * (self.cur - self.min) / (self.max - self.min)
1325
- result = '%3d %%' % v
1326
- return result
1327
-
1328
- def format_duration(self, duration):
1329
- if (duration <= 0) and self.max is None or self.cur == self.min:
1330
- result = '??:??:??'
1331
- #elif duration < 1:
1332
- # result = '--:--:--'
1333
- else:
1334
- result = time.strftime('%H:%M:%S', time.gmtime(duration))
1335
- return result
1336
-
1337
- @property
1338
- def ETA(self):
1339
- if self.done:
1340
- prefix = 'Done'
1341
- t = self.elapsed
1342
- #import pdb; pdb.set_trace()
1343
- else:
1344
- prefix = 'ETA '
1345
- if self.max is None:
1346
- t = -1
1347
- elif self.elapsed == 0 or (self.cur == self.min):
1348
- t = 0
1349
- else:
1350
- #import pdb; pdb.set_trace()
1351
- t = float(self.max - self.min)
1352
- t /= self.cur - self.min
1353
- t = (t - 1) * self.elapsed
1354
- return '%s: %s' % (prefix, self.format_duration(t))
1355
-
1356
- @property
1357
- def speed(self):
1358
- if self.elapsed == 0:
1359
- result = 0.0
1360
- else:
1361
- result = (self.cur - self.min) / self.elapsed
1362
- for unit in UNITS:
1363
- if result < 1000:
1364
- break
1365
- result /= 1000.0
1366
- return '%d %sB/s' % (result, unit)
1367
-
1368
- #
1369
- # Glob functionality
1370
- #
1371
-
1372
- RICH_GLOB = re.compile(r'\{([^}]*)\}')
1373
- _CHECK_RECURSIVE_GLOB = re.compile(r'[^/\\,{]\*\*|\*\*[^/\\,}]')
1374
- _CHECK_MISMATCH_SET = re.compile(r'^[^{]*\}|\{[^}]*$')
1375
-
1376
-
1377
- def iglob(path_glob):
1378
- """Extended globbing function that supports ** and {opt1,opt2,opt3}."""
1379
- if _CHECK_RECURSIVE_GLOB.search(path_glob):
1380
- msg = """invalid glob %r: recursive glob "**" must be used alone"""
1381
- raise ValueError(msg % path_glob)
1382
- if _CHECK_MISMATCH_SET.search(path_glob):
1383
- msg = """invalid glob %r: mismatching set marker '{' or '}'"""
1384
- raise ValueError(msg % path_glob)
1385
- return _iglob(path_glob)
1386
-
1387
-
1388
- def _iglob(path_glob):
1389
- rich_path_glob = RICH_GLOB.split(path_glob, 1)
1390
- if len(rich_path_glob) > 1:
1391
- assert len(rich_path_glob) == 3, rich_path_glob
1392
- prefix, set, suffix = rich_path_glob
1393
- for item in set.split(','):
1394
- for path in _iglob(''.join((prefix, item, suffix))):
1395
- yield path
1396
- else:
1397
- if '**' not in path_glob:
1398
- for item in std_iglob(path_glob):
1399
- yield item
1400
- else:
1401
- prefix, radical = path_glob.split('**', 1)
1402
- if prefix == '':
1403
- prefix = '.'
1404
- if radical == '':
1405
- radical = '*'
1406
- else:
1407
- # we support both
1408
- radical = radical.lstrip('/')
1409
- radical = radical.lstrip('\\')
1410
- for path, dir, files in os.walk(prefix):
1411
- path = os.path.normpath(path)
1412
- for fn in _iglob(os.path.join(path, radical)):
1413
- yield fn
1414
-
1415
- if ssl:
1416
- from .compat import (HTTPSHandler as BaseHTTPSHandler, match_hostname,
1417
- CertificateError)
1418
-
1419
-
1420
- #
1421
- # HTTPSConnection which verifies certificates/matches domains
1422
- #
1423
-
1424
- class HTTPSConnection(httplib.HTTPSConnection):
1425
- ca_certs = None # set this to the path to the certs file (.pem)
1426
- check_domain = True # only used if ca_certs is not None
1427
-
1428
- # noinspection PyPropertyAccess
1429
- def connect(self):
1430
- sock = socket.create_connection((self.host, self.port), self.timeout)
1431
- if getattr(self, '_tunnel_host', False):
1432
- self.sock = sock
1433
- self._tunnel()
1434
-
1435
- if not hasattr(ssl, 'SSLContext'):
1436
- # For 2.x
1437
- if self.ca_certs:
1438
- cert_reqs = ssl.CERT_REQUIRED
1439
- else:
1440
- cert_reqs = ssl.CERT_NONE
1441
- self.sock = ssl.wrap_socket(sock, self.key_file, self.cert_file,
1442
- cert_reqs=cert_reqs,
1443
- ssl_version=ssl.PROTOCOL_SSLv23,
1444
- ca_certs=self.ca_certs)
1445
- else: # pragma: no cover
1446
- context = ssl.SSLContext(ssl.PROTOCOL_SSLv23)
1447
- if hasattr(ssl, 'OP_NO_SSLv2'):
1448
- context.options |= ssl.OP_NO_SSLv2
1449
- if self.cert_file:
1450
- context.load_cert_chain(self.cert_file, self.key_file)
1451
- kwargs = {}
1452
- if self.ca_certs:
1453
- context.verify_mode = ssl.CERT_REQUIRED
1454
- context.load_verify_locations(cafile=self.ca_certs)
1455
- if getattr(ssl, 'HAS_SNI', False):
1456
- kwargs['server_hostname'] = self.host
1457
- self.sock = context.wrap_socket(sock, **kwargs)
1458
- if self.ca_certs and self.check_domain:
1459
- try:
1460
- match_hostname(self.sock.getpeercert(), self.host)
1461
- logger.debug('Host verified: %s', self.host)
1462
- except CertificateError: # pragma: no cover
1463
- self.sock.shutdown(socket.SHUT_RDWR)
1464
- self.sock.close()
1465
- raise
1466
-
1467
- class HTTPSHandler(BaseHTTPSHandler):
1468
- def __init__(self, ca_certs, check_domain=True):
1469
- BaseHTTPSHandler.__init__(self)
1470
- self.ca_certs = ca_certs
1471
- self.check_domain = check_domain
1472
-
1473
- def _conn_maker(self, *args, **kwargs):
1474
- """
1475
- This is called to create a connection instance. Normally you'd
1476
- pass a connection class to do_open, but it doesn't actually check for
1477
- a class, and just expects a callable. As long as we behave just as a
1478
- constructor would have, we should be OK. If it ever changes so that
1479
- we *must* pass a class, we'll create an UnsafeHTTPSConnection class
1480
- which just sets check_domain to False in the class definition, and
1481
- choose which one to pass to do_open.
1482
- """
1483
- result = HTTPSConnection(*args, **kwargs)
1484
- if self.ca_certs:
1485
- result.ca_certs = self.ca_certs
1486
- result.check_domain = self.check_domain
1487
- return result
1488
-
1489
- def https_open(self, req):
1490
- try:
1491
- return self.do_open(self._conn_maker, req)
1492
- except URLError as e:
1493
- if 'certificate verify failed' in str(e.reason):
1494
- raise CertificateError('Unable to verify server certificate '
1495
- 'for %s' % req.host)
1496
- else:
1497
- raise
1498
-
1499
- #
1500
- # To prevent against mixing HTTP traffic with HTTPS (examples: A Man-In-The-
1501
- # Middle proxy using HTTP listens on port 443, or an index mistakenly serves
1502
- # HTML containing a http://xyz link when it should be https://xyz),
1503
- # you can use the following handler class, which does not allow HTTP traffic.
1504
- #
1505
- # It works by inheriting from HTTPHandler - so build_opener won't add a
1506
- # handler for HTTP itself.
1507
- #
1508
- class HTTPSOnlyHandler(HTTPSHandler, HTTPHandler):
1509
- def http_open(self, req):
1510
- raise URLError('Unexpected HTTP request on what should be a secure '
1511
- 'connection: %s' % req)
1512
-
1513
- #
1514
- # XML-RPC with timeouts
1515
- #
1516
-
1517
- _ver_info = sys.version_info[:2]
1518
-
1519
- if _ver_info == (2, 6):
1520
- class HTTP(httplib.HTTP):
1521
- def __init__(self, host='', port=None, **kwargs):
1522
- if port == 0: # 0 means use port 0, not the default port
1523
- port = None
1524
- self._setup(self._connection_class(host, port, **kwargs))
1525
-
1526
-
1527
- if ssl:
1528
- class HTTPS(httplib.HTTPS):
1529
- def __init__(self, host='', port=None, **kwargs):
1530
- if port == 0: # 0 means use port 0, not the default port
1531
- port = None
1532
- self._setup(self._connection_class(host, port, **kwargs))
1533
-
1534
-
1535
- class Transport(xmlrpclib.Transport):
1536
- def __init__(self, timeout, use_datetime=0):
1537
- self.timeout = timeout
1538
- xmlrpclib.Transport.__init__(self, use_datetime)
1539
-
1540
- def make_connection(self, host):
1541
- h, eh, x509 = self.get_host_info(host)
1542
- if _ver_info == (2, 6):
1543
- result = HTTP(h, timeout=self.timeout)
1544
- else:
1545
- if not self._connection or host != self._connection[0]:
1546
- self._extra_headers = eh
1547
- self._connection = host, httplib.HTTPConnection(h)
1548
- result = self._connection[1]
1549
- return result
1550
-
1551
- if ssl:
1552
- class SafeTransport(xmlrpclib.SafeTransport):
1553
- def __init__(self, timeout, use_datetime=0):
1554
- self.timeout = timeout
1555
- xmlrpclib.SafeTransport.__init__(self, use_datetime)
1556
-
1557
- def make_connection(self, host):
1558
- h, eh, kwargs = self.get_host_info(host)
1559
- if not kwargs:
1560
- kwargs = {}
1561
- kwargs['timeout'] = self.timeout
1562
- if _ver_info == (2, 6):
1563
- result = HTTPS(host, None, **kwargs)
1564
- else:
1565
- if not self._connection or host != self._connection[0]:
1566
- self._extra_headers = eh
1567
- self._connection = host, httplib.HTTPSConnection(h, None,
1568
- **kwargs)
1569
- result = self._connection[1]
1570
- return result
1571
-
1572
-
1573
- class ServerProxy(xmlrpclib.ServerProxy):
1574
- def __init__(self, uri, **kwargs):
1575
- self.timeout = timeout = kwargs.pop('timeout', None)
1576
- # The above classes only come into play if a timeout
1577
- # is specified
1578
- if timeout is not None:
1579
- # scheme = splittype(uri) # deprecated as of Python 3.8
1580
- scheme = urlparse(uri)[0]
1581
- use_datetime = kwargs.get('use_datetime', 0)
1582
- if scheme == 'https':
1583
- tcls = SafeTransport
1584
- else:
1585
- tcls = Transport
1586
- kwargs['transport'] = t = tcls(timeout, use_datetime=use_datetime)
1587
- self.transport = t
1588
- xmlrpclib.ServerProxy.__init__(self, uri, **kwargs)
1589
-
1590
- #
1591
- # CSV functionality. This is provided because on 2.x, the csv module can't
1592
- # handle Unicode. However, we need to deal with Unicode in e.g. RECORD files.
1593
- #
1594
-
1595
- def _csv_open(fn, mode, **kwargs):
1596
- if sys.version_info[0] < 3:
1597
- mode += 'b'
1598
- else:
1599
- kwargs['newline'] = ''
1600
- # Python 3 determines encoding from locale. Force 'utf-8'
1601
- # file encoding to match other forced utf-8 encoding
1602
- kwargs['encoding'] = 'utf-8'
1603
- return open(fn, mode, **kwargs)
1604
-
1605
-
1606
- class CSVBase(object):
1607
- defaults = {
1608
- 'delimiter': str(','), # The strs are used because we need native
1609
- 'quotechar': str('"'), # str in the csv API (2.x won't take
1610
- 'lineterminator': str('\n') # Unicode)
1611
- }
1612
-
1613
- def __enter__(self):
1614
- return self
1615
-
1616
- def __exit__(self, *exc_info):
1617
- self.stream.close()
1618
-
1619
-
1620
- class CSVReader(CSVBase):
1621
- def __init__(self, **kwargs):
1622
- if 'stream' in kwargs:
1623
- stream = kwargs['stream']
1624
- if sys.version_info[0] >= 3:
1625
- # needs to be a text stream
1626
- stream = codecs.getreader('utf-8')(stream)
1627
- self.stream = stream
1628
- else:
1629
- self.stream = _csv_open(kwargs['path'], 'r')
1630
- self.reader = csv.reader(self.stream, **self.defaults)
1631
-
1632
- def __iter__(self):
1633
- return self
1634
-
1635
- def next(self):
1636
- result = next(self.reader)
1637
- if sys.version_info[0] < 3:
1638
- for i, item in enumerate(result):
1639
- if not isinstance(item, text_type):
1640
- result[i] = item.decode('utf-8')
1641
- return result
1642
-
1643
- __next__ = next
1644
-
1645
- class CSVWriter(CSVBase):
1646
- def __init__(self, fn, **kwargs):
1647
- self.stream = _csv_open(fn, 'w')
1648
- self.writer = csv.writer(self.stream, **self.defaults)
1649
-
1650
- def writerow(self, row):
1651
- if sys.version_info[0] < 3:
1652
- r = []
1653
- for item in row:
1654
- if isinstance(item, text_type):
1655
- item = item.encode('utf-8')
1656
- r.append(item)
1657
- row = r
1658
- self.writer.writerow(row)
1659
-
1660
- #
1661
- # Configurator functionality
1662
- #
1663
-
1664
- class Configurator(BaseConfigurator):
1665
-
1666
- value_converters = dict(BaseConfigurator.value_converters)
1667
- value_converters['inc'] = 'inc_convert'
1668
-
1669
- def __init__(self, config, base=None):
1670
- super(Configurator, self).__init__(config)
1671
- self.base = base or os.getcwd()
1672
-
1673
- def configure_custom(self, config):
1674
- def convert(o):
1675
- if isinstance(o, (list, tuple)):
1676
- result = type(o)([convert(i) for i in o])
1677
- elif isinstance(o, dict):
1678
- if '()' in o:
1679
- result = self.configure_custom(o)
1680
- else:
1681
- result = {}
1682
- for k in o:
1683
- result[k] = convert(o[k])
1684
- else:
1685
- result = self.convert(o)
1686
- return result
1687
-
1688
- c = config.pop('()')
1689
- if not callable(c):
1690
- c = self.resolve(c)
1691
- props = config.pop('.', None)
1692
- # Check for valid identifiers
1693
- args = config.pop('[]', ())
1694
- if args:
1695
- args = tuple([convert(o) for o in args])
1696
- items = [(k, convert(config[k])) for k in config if valid_ident(k)]
1697
- kwargs = dict(items)
1698
- result = c(*args, **kwargs)
1699
- if props:
1700
- for n, v in props.items():
1701
- setattr(result, n, convert(v))
1702
- return result
1703
-
1704
- def __getitem__(self, key):
1705
- result = self.config[key]
1706
- if isinstance(result, dict) and '()' in result:
1707
- self.config[key] = result = self.configure_custom(result)
1708
- return result
1709
-
1710
- def inc_convert(self, value):
1711
- """Default converter for the inc:// protocol."""
1712
- if not os.path.isabs(value):
1713
- value = os.path.join(self.base, value)
1714
- with codecs.open(value, 'r', encoding='utf-8') as f:
1715
- result = json.load(f)
1716
- return result
1717
-
1718
-
1719
- class SubprocessMixin(object):
1720
- """
1721
- Mixin for running subprocesses and capturing their output
1722
- """
1723
- def __init__(self, verbose=False, progress=None):
1724
- self.verbose = verbose
1725
- self.progress = progress
1726
-
1727
- def reader(self, stream, context):
1728
- """
1729
- Read lines from a subprocess' output stream and either pass to a progress
1730
- callable (if specified) or write progress information to sys.stderr.
1731
- """
1732
- progress = self.progress
1733
- verbose = self.verbose
1734
- while True:
1735
- s = stream.readline()
1736
- if not s:
1737
- break
1738
- if progress is not None:
1739
- progress(s, context)
1740
- else:
1741
- if not verbose:
1742
- sys.stderr.write('.')
1743
- else:
1744
- sys.stderr.write(s.decode('utf-8'))
1745
- sys.stderr.flush()
1746
- stream.close()
1747
-
1748
- def run_command(self, cmd, **kwargs):
1749
- p = subprocess.Popen(cmd, stdout=subprocess.PIPE,
1750
- stderr=subprocess.PIPE, **kwargs)
1751
- t1 = threading.Thread(target=self.reader, args=(p.stdout, 'stdout'))
1752
- t1.start()
1753
- t2 = threading.Thread(target=self.reader, args=(p.stderr, 'stderr'))
1754
- t2.start()
1755
- p.wait()
1756
- t1.join()
1757
- t2.join()
1758
- if self.progress is not None:
1759
- self.progress('done.', 'main')
1760
- elif self.verbose:
1761
- sys.stderr.write('done.\n')
1762
- return p
1763
-
1764
-
1765
- def normalize_name(name):
1766
- """Normalize a python package name a la PEP 503"""
1767
- # https://www.python.org/dev/peps/pep-0503/#normalized-names
1768
- return re.sub('[-_.]+', '-', name).lower()
1769
-
1770
- # def _get_pypirc_command():
1771
- # """
1772
- # Get the distutils command for interacting with PyPI configurations.
1773
- # :return: the command.
1774
- # """
1775
- # from distutils.core import Distribution
1776
- # from distutils.config import PyPIRCCommand
1777
- # d = Distribution()
1778
- # return PyPIRCCommand(d)
1779
-
1780
- class PyPIRCFile(object):
1781
-
1782
- DEFAULT_REPOSITORY = 'https://upload.pypi.org/legacy/'
1783
- DEFAULT_REALM = 'pypi'
1784
-
1785
- def __init__(self, fn=None, url=None):
1786
- if fn is None:
1787
- fn = os.path.join(os.path.expanduser('~'), '.pypirc')
1788
- self.filename = fn
1789
- self.url = url
1790
-
1791
- def read(self):
1792
- result = {}
1793
-
1794
- if os.path.exists(self.filename):
1795
- repository = self.url or self.DEFAULT_REPOSITORY
1796
-
1797
- config = configparser.RawConfigParser()
1798
- config.read(self.filename)
1799
- sections = config.sections()
1800
- if 'distutils' in sections:
1801
- # let's get the list of servers
1802
- index_servers = config.get('distutils', 'index-servers')
1803
- _servers = [server.strip() for server in
1804
- index_servers.split('\n')
1805
- if server.strip() != '']
1806
- if _servers == []:
1807
- # nothing set, let's try to get the default pypi
1808
- if 'pypi' in sections:
1809
- _servers = ['pypi']
1810
- else:
1811
- for server in _servers:
1812
- result = {'server': server}
1813
- result['username'] = config.get(server, 'username')
1814
-
1815
- # optional params
1816
- for key, default in (('repository', self.DEFAULT_REPOSITORY),
1817
- ('realm', self.DEFAULT_REALM),
1818
- ('password', None)):
1819
- if config.has_option(server, key):
1820
- result[key] = config.get(server, key)
1821
- else:
1822
- result[key] = default
1823
-
1824
- # work around people having "repository" for the "pypi"
1825
- # section of their config set to the HTTP (rather than
1826
- # HTTPS) URL
1827
- if (server == 'pypi' and
1828
- repository in (self.DEFAULT_REPOSITORY, 'pypi')):
1829
- result['repository'] = self.DEFAULT_REPOSITORY
1830
- elif (result['server'] != repository and
1831
- result['repository'] != repository):
1832
- result = {}
1833
- elif 'server-login' in sections:
1834
- # old format
1835
- server = 'server-login'
1836
- if config.has_option(server, 'repository'):
1837
- repository = config.get(server, 'repository')
1838
- else:
1839
- repository = self.DEFAULT_REPOSITORY
1840
- result = {
1841
- 'username': config.get(server, 'username'),
1842
- 'password': config.get(server, 'password'),
1843
- 'repository': repository,
1844
- 'server': server,
1845
- 'realm': self.DEFAULT_REALM
1846
- }
1847
- return result
1848
-
1849
- def update(self, username, password):
1850
- # import pdb; pdb.set_trace()
1851
- config = configparser.RawConfigParser()
1852
- fn = self.filename
1853
- config.read(fn)
1854
- if not config.has_section('pypi'):
1855
- config.add_section('pypi')
1856
- config.set('pypi', 'username', username)
1857
- config.set('pypi', 'password', password)
1858
- with open(fn, 'w') as f:
1859
- config.write(f)
1860
-
1861
- def _load_pypirc(index):
1862
- """
1863
- Read the PyPI access configuration as supported by distutils.
1864
- """
1865
- return PyPIRCFile(url=index.url).read()
1866
-
1867
- def _store_pypirc(index):
1868
- PyPIRCFile().update(index.username, index.password)
1869
-
1870
- #
1871
- # get_platform()/get_host_platform() copied from Python 3.10.a0 source, with some minor
1872
- # tweaks
1873
- #
1874
-
1875
- def get_host_platform():
1876
- """Return a string that identifies the current platform. This is used mainly to
1877
- distinguish platform-specific build directories and platform-specific built
1878
- distributions. Typically includes the OS name and version and the
1879
- architecture (as supplied by 'os.uname()'), although the exact information
1880
- included depends on the OS; eg. on Linux, the kernel version isn't
1881
- particularly important.
1882
-
1883
- Examples of returned values:
1884
- linux-i586
1885
- linux-alpha (?)
1886
- solaris-2.6-sun4u
1887
-
1888
- Windows will return one of:
1889
- win-amd64 (64bit Windows on AMD64 (aka x86_64, Intel64, EM64T, etc)
1890
- win32 (all others - specifically, sys.platform is returned)
1891
-
1892
- For other non-POSIX platforms, currently just returns 'sys.platform'.
1893
-
1894
- """
1895
- if os.name == 'nt':
1896
- if 'amd64' in sys.version.lower():
1897
- return 'win-amd64'
1898
- if '(arm)' in sys.version.lower():
1899
- return 'win-arm32'
1900
- if '(arm64)' in sys.version.lower():
1901
- return 'win-arm64'
1902
- return sys.platform
1903
-
1904
- # Set for cross builds explicitly
1905
- if "_PYTHON_HOST_PLATFORM" in os.environ:
1906
- return os.environ["_PYTHON_HOST_PLATFORM"]
1907
-
1908
- if os.name != 'posix' or not hasattr(os, 'uname'):
1909
- # XXX what about the architecture? NT is Intel or Alpha,
1910
- # Mac OS is M68k or PPC, etc.
1911
- return sys.platform
1912
-
1913
- # Try to distinguish various flavours of Unix
1914
-
1915
- (osname, host, release, version, machine) = os.uname()
1916
-
1917
- # Convert the OS name to lowercase, remove '/' characters, and translate
1918
- # spaces (for "Power Macintosh")
1919
- osname = osname.lower().replace('/', '')
1920
- machine = machine.replace(' ', '_').replace('/', '-')
1921
-
1922
- if osname[:5] == 'linux':
1923
- # At least on Linux/Intel, 'machine' is the processor --
1924
- # i386, etc.
1925
- # XXX what about Alpha, SPARC, etc?
1926
- return "%s-%s" % (osname, machine)
1927
-
1928
- elif osname[:5] == 'sunos':
1929
- if release[0] >= '5': # SunOS 5 == Solaris 2
1930
- osname = 'solaris'
1931
- release = '%d.%s' % (int(release[0]) - 3, release[2:])
1932
- # We can't use 'platform.architecture()[0]' because a
1933
- # bootstrap problem. We use a dict to get an error
1934
- # if some suspicious happens.
1935
- bitness = {2147483647:'32bit', 9223372036854775807:'64bit'}
1936
- machine += '.%s' % bitness[sys.maxsize]
1937
- # fall through to standard osname-release-machine representation
1938
- elif osname[:3] == 'aix':
1939
- from _aix_support import aix_platform
1940
- return aix_platform()
1941
- elif osname[:6] == 'cygwin':
1942
- osname = 'cygwin'
1943
- rel_re = re.compile (r'[\d.]+', re.ASCII)
1944
- m = rel_re.match(release)
1945
- if m:
1946
- release = m.group()
1947
- elif osname[:6] == 'darwin':
1948
- import _osx_support, distutils.sysconfig
1949
- osname, release, machine = _osx_support.get_platform_osx(
1950
- distutils.sysconfig.get_config_vars(),
1951
- osname, release, machine)
1952
-
1953
- return '%s-%s-%s' % (osname, release, machine)
1954
-
1955
-
1956
- _TARGET_TO_PLAT = {
1957
- 'x86' : 'win32',
1958
- 'x64' : 'win-amd64',
1959
- 'arm' : 'win-arm32',
1960
- }
1961
-
1962
-
1963
- def get_platform():
1964
- if os.name != 'nt':
1965
- return get_host_platform()
1966
- cross_compilation_target = os.environ.get('VSCMD_ARG_TGT_ARCH')
1967
- if cross_compilation_target not in _TARGET_TO_PLAT:
1968
- return get_host_platform()
1969
- return _TARGET_TO_PLAT[cross_compilation_target]