ayousanz commited on
Commit
4a017e3
·
verified ·
1 Parent(s): 663e67c

Add files using upload-large-folder tool

Browse files
This view is limited to 50 files because it contains too many changes.   See raw diff
Files changed (50) hide show
  1. .gitattributes +4 -0
  2. .venv/Lib/site-packages/scipy/stats/_boost/binom_ufunc.cp39-win_amd64.pyd +3 -0
  3. .venv/Lib/site-packages/scipy/stats/_boost/hypergeom_ufunc.cp39-win_amd64.pyd +3 -0
  4. .venv/Lib/site-packages/scipy/stats/_boost/nbinom_ufunc.cp39-win_amd64.pyd +3 -0
  5. .venv/Lib/site-packages/scipy/stats/_boost/nct_ufunc.cp39-win_amd64.pyd +3 -0
  6. .venv/Lib/site-packages/setuptools/_vendor/autocommand-2.2.2.dist-info/WHEEL +5 -0
  7. .venv/Lib/site-packages/setuptools/_vendor/backports/__init__.py +1 -0
  8. .venv/Lib/site-packages/setuptools/_vendor/backports/__pycache__/__init__.cpython-39.pyc +0 -0
  9. .venv/Lib/site-packages/setuptools/_vendor/backports/tarfile/__init__.py +0 -0
  10. .venv/Lib/site-packages/setuptools/_vendor/backports/tarfile/__main__.py +5 -0
  11. .venv/Lib/site-packages/setuptools/_vendor/backports/tarfile/__pycache__/__init__.cpython-39.pyc +0 -0
  12. .venv/Lib/site-packages/setuptools/_vendor/backports/tarfile/compat/__init__.py +0 -0
  13. .venv/Lib/site-packages/setuptools/_vendor/backports/tarfile/compat/__pycache__/__init__.cpython-39.pyc +0 -0
  14. .venv/Lib/site-packages/setuptools/_vendor/backports/tarfile/compat/__pycache__/py38.cpython-39.pyc +0 -0
  15. .venv/Lib/site-packages/setuptools/_vendor/backports/tarfile/compat/py38.py +24 -0
  16. .venv/Lib/site-packages/setuptools/_vendor/importlib_metadata-8.0.0.dist-info/INSTALLER +1 -0
  17. .venv/Lib/site-packages/setuptools/_vendor/importlib_metadata-8.0.0.dist-info/LICENSE +202 -0
  18. .venv/Lib/site-packages/setuptools/_vendor/importlib_metadata-8.0.0.dist-info/METADATA +129 -0
  19. .venv/Lib/site-packages/setuptools/_vendor/importlib_metadata-8.0.0.dist-info/RECORD +32 -0
  20. .venv/Lib/site-packages/setuptools/_vendor/importlib_metadata-8.0.0.dist-info/REQUESTED +0 -0
  21. .venv/Lib/site-packages/setuptools/_vendor/importlib_metadata-8.0.0.dist-info/WHEEL +5 -0
  22. .venv/Lib/site-packages/setuptools/_vendor/importlib_metadata-8.0.0.dist-info/top_level.txt +1 -0
  23. .venv/Lib/site-packages/setuptools/_vendor/importlib_metadata/__init__.py +1083 -0
  24. .venv/Lib/site-packages/setuptools/_vendor/importlib_metadata/__pycache__/__init__.cpython-39.pyc +0 -0
  25. .venv/Lib/site-packages/setuptools/_vendor/importlib_metadata/__pycache__/_adapters.cpython-39.pyc +0 -0
  26. .venv/Lib/site-packages/setuptools/_vendor/importlib_metadata/__pycache__/_collections.cpython-39.pyc +0 -0
  27. .venv/Lib/site-packages/setuptools/_vendor/importlib_metadata/__pycache__/_compat.cpython-39.pyc +0 -0
  28. .venv/Lib/site-packages/setuptools/_vendor/importlib_metadata/__pycache__/_functools.cpython-39.pyc +0 -0
  29. .venv/Lib/site-packages/setuptools/_vendor/importlib_metadata/__pycache__/_itertools.cpython-39.pyc +0 -0
  30. .venv/Lib/site-packages/setuptools/_vendor/importlib_metadata/__pycache__/_meta.cpython-39.pyc +0 -0
  31. .venv/Lib/site-packages/setuptools/_vendor/importlib_metadata/__pycache__/_text.cpython-39.pyc +0 -0
  32. .venv/Lib/site-packages/setuptools/_vendor/importlib_metadata/_collections.py +30 -0
  33. .venv/Lib/site-packages/setuptools/_vendor/importlib_metadata/_compat.py +57 -0
  34. .venv/Lib/site-packages/setuptools/_vendor/importlib_metadata/_functools.py +104 -0
  35. .venv/Lib/site-packages/setuptools/_vendor/importlib_metadata/_itertools.py +73 -0
  36. .venv/Lib/site-packages/setuptools/_vendor/importlib_metadata/_meta.py +67 -0
  37. .venv/Lib/site-packages/setuptools/_vendor/importlib_metadata/_text.py +99 -0
  38. .venv/Lib/site-packages/setuptools/_vendor/importlib_metadata/compat/__init__.py +0 -0
  39. .venv/Lib/site-packages/setuptools/_vendor/importlib_metadata/compat/__pycache__/__init__.cpython-39.pyc +0 -0
  40. .venv/Lib/site-packages/setuptools/_vendor/importlib_metadata/compat/__pycache__/py311.cpython-39.pyc +0 -0
  41. .venv/Lib/site-packages/setuptools/_vendor/importlib_metadata/compat/__pycache__/py39.cpython-39.pyc +0 -0
  42. .venv/Lib/site-packages/setuptools/_vendor/importlib_metadata/compat/py311.py +22 -0
  43. .venv/Lib/site-packages/setuptools/_vendor/importlib_metadata/compat/py39.py +36 -0
  44. .venv/Lib/site-packages/setuptools/_vendor/inflect/__init__.py +0 -0
  45. .venv/Lib/site-packages/setuptools/_vendor/inflect/py.typed +0 -0
  46. .venv/Lib/site-packages/setuptools/_vendor/jaraco.functools-4.0.1.dist-info/RECORD +10 -0
  47. .venv/Lib/site-packages/setuptools/_vendor/jaraco.functools-4.0.1.dist-info/WHEEL +5 -0
  48. .venv/Lib/site-packages/setuptools/_vendor/jaraco.functools-4.0.1.dist-info/top_level.txt +1 -0
  49. .venv/Lib/site-packages/setuptools/_vendor/jaraco.text-3.12.1.dist-info/INSTALLER +1 -0
  50. .venv/Lib/site-packages/setuptools/_vendor/jaraco.text-3.12.1.dist-info/LICENSE +17 -0
.gitattributes CHANGED
@@ -104,3 +104,7 @@ reference_sample_wavs/syuukovoice_200918_3_01.wav filter=lfs diff=lfs merge=lfs
104
  .venv/Lib/site-packages/scipy/special/cython_special.cp39-win_amd64.pyd filter=lfs diff=lfs merge=lfs -text
105
  .venv/Lib/site-packages/scipy/stats/_boost/beta_ufunc.cp39-win_amd64.pyd filter=lfs diff=lfs merge=lfs -text
106
  .venv/Lib/site-packages/scipy/stats/_boost/ncf_ufunc.cp39-win_amd64.pyd filter=lfs diff=lfs merge=lfs -text
 
 
 
 
 
104
  .venv/Lib/site-packages/scipy/special/cython_special.cp39-win_amd64.pyd filter=lfs diff=lfs merge=lfs -text
105
  .venv/Lib/site-packages/scipy/stats/_boost/beta_ufunc.cp39-win_amd64.pyd filter=lfs diff=lfs merge=lfs -text
106
  .venv/Lib/site-packages/scipy/stats/_boost/ncf_ufunc.cp39-win_amd64.pyd filter=lfs diff=lfs merge=lfs -text
107
+ .venv/Lib/site-packages/scipy/stats/_boost/nbinom_ufunc.cp39-win_amd64.pyd filter=lfs diff=lfs merge=lfs -text
108
+ .venv/Lib/site-packages/scipy/stats/_boost/binom_ufunc.cp39-win_amd64.pyd filter=lfs diff=lfs merge=lfs -text
109
+ .venv/Lib/site-packages/scipy/stats/_boost/hypergeom_ufunc.cp39-win_amd64.pyd filter=lfs diff=lfs merge=lfs -text
110
+ .venv/Lib/site-packages/scipy/stats/_boost/nct_ufunc.cp39-win_amd64.pyd filter=lfs diff=lfs merge=lfs -text
.venv/Lib/site-packages/scipy/stats/_boost/binom_ufunc.cp39-win_amd64.pyd ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:0d1c93bb8e75bda8dbe60c5848bf49cc1118ded57c504dfbd92dbdfb9859568a
3
+ size 1036288
.venv/Lib/site-packages/scipy/stats/_boost/hypergeom_ufunc.cp39-win_amd64.pyd ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:5ea663551b476b20a4a33b24ce0486ff3838f3b029ff5b37573b11948aae270e
3
+ size 1002496
.venv/Lib/site-packages/scipy/stats/_boost/nbinom_ufunc.cp39-win_amd64.pyd ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:51b970d5ee0003ca8343d12b01361469627a4ad8266209edad66854647601f81
3
+ size 1037824
.venv/Lib/site-packages/scipy/stats/_boost/nct_ufunc.cp39-win_amd64.pyd ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:495695dea3bbb2311934f4318ffb5dab0a3f3c24ae26e6395d49bb2a618be75d
3
+ size 1071104
.venv/Lib/site-packages/setuptools/_vendor/autocommand-2.2.2.dist-info/WHEEL ADDED
@@ -0,0 +1,5 @@
 
 
 
 
 
 
1
+ Wheel-Version: 1.0
2
+ Generator: bdist_wheel (0.38.4)
3
+ Root-Is-Purelib: true
4
+ Tag: py3-none-any
5
+
.venv/Lib/site-packages/setuptools/_vendor/backports/__init__.py ADDED
@@ -0,0 +1 @@
 
 
1
+ __path__ = __import__('pkgutil').extend_path(__path__, __name__) # type: ignore
.venv/Lib/site-packages/setuptools/_vendor/backports/__pycache__/__init__.cpython-39.pyc ADDED
Binary file (267 Bytes). View file
 
.venv/Lib/site-packages/setuptools/_vendor/backports/tarfile/__init__.py ADDED
The diff for this file is too large to render. See raw diff
 
.venv/Lib/site-packages/setuptools/_vendor/backports/tarfile/__main__.py ADDED
@@ -0,0 +1,5 @@
 
 
 
 
 
 
1
+ from . import main
2
+
3
+
4
+ if __name__ == '__main__':
5
+ main()
.venv/Lib/site-packages/setuptools/_vendor/backports/tarfile/__pycache__/__init__.cpython-39.pyc ADDED
Binary file (72.4 kB). View file
 
.venv/Lib/site-packages/setuptools/_vendor/backports/tarfile/compat/__init__.py ADDED
File without changes
.venv/Lib/site-packages/setuptools/_vendor/backports/tarfile/compat/__pycache__/__init__.cpython-39.pyc ADDED
Binary file (215 Bytes). View file
 
.venv/Lib/site-packages/setuptools/_vendor/backports/tarfile/compat/__pycache__/py38.cpython-39.pyc ADDED
Binary file (815 Bytes). View file
 
.venv/Lib/site-packages/setuptools/_vendor/backports/tarfile/compat/py38.py ADDED
@@ -0,0 +1,24 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import sys
2
+
3
+
4
+ if sys.version_info < (3, 9):
5
+
6
+ def removesuffix(self, suffix):
7
+ # suffix='' should not call self[:-0].
8
+ if suffix and self.endswith(suffix):
9
+ return self[: -len(suffix)]
10
+ else:
11
+ return self[:]
12
+
13
+ def removeprefix(self, prefix):
14
+ if self.startswith(prefix):
15
+ return self[len(prefix) :]
16
+ else:
17
+ return self[:]
18
+ else:
19
+
20
+ def removesuffix(self, suffix):
21
+ return self.removesuffix(suffix)
22
+
23
+ def removeprefix(self, prefix):
24
+ return self.removeprefix(prefix)
.venv/Lib/site-packages/setuptools/_vendor/importlib_metadata-8.0.0.dist-info/INSTALLER ADDED
@@ -0,0 +1 @@
 
 
1
+ pip
.venv/Lib/site-packages/setuptools/_vendor/importlib_metadata-8.0.0.dist-info/LICENSE ADDED
@@ -0,0 +1,202 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+
2
+ Apache License
3
+ Version 2.0, January 2004
4
+ http://www.apache.org/licenses/
5
+
6
+ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
7
+
8
+ 1. Definitions.
9
+
10
+ "License" shall mean the terms and conditions for use, reproduction,
11
+ and distribution as defined by Sections 1 through 9 of this document.
12
+
13
+ "Licensor" shall mean the copyright owner or entity authorized by
14
+ the copyright owner that is granting the License.
15
+
16
+ "Legal Entity" shall mean the union of the acting entity and all
17
+ other entities that control, are controlled by, or are under common
18
+ control with that entity. For the purposes of this definition,
19
+ "control" means (i) the power, direct or indirect, to cause the
20
+ direction or management of such entity, whether by contract or
21
+ otherwise, or (ii) ownership of fifty percent (50%) or more of the
22
+ outstanding shares, or (iii) beneficial ownership of such entity.
23
+
24
+ "You" (or "Your") shall mean an individual or Legal Entity
25
+ exercising permissions granted by this License.
26
+
27
+ "Source" form shall mean the preferred form for making modifications,
28
+ including but not limited to software source code, documentation
29
+ source, and configuration files.
30
+
31
+ "Object" form shall mean any form resulting from mechanical
32
+ transformation or translation of a Source form, including but
33
+ not limited to compiled object code, generated documentation,
34
+ and conversions to other media types.
35
+
36
+ "Work" shall mean the work of authorship, whether in Source or
37
+ Object form, made available under the License, as indicated by a
38
+ copyright notice that is included in or attached to the work
39
+ (an example is provided in the Appendix below).
40
+
41
+ "Derivative Works" shall mean any work, whether in Source or Object
42
+ form, that is based on (or derived from) the Work and for which the
43
+ editorial revisions, annotations, elaborations, or other modifications
44
+ represent, as a whole, an original work of authorship. For the purposes
45
+ of this License, Derivative Works shall not include works that remain
46
+ separable from, or merely link (or bind by name) to the interfaces of,
47
+ the Work and Derivative Works thereof.
48
+
49
+ "Contribution" shall mean any work of authorship, including
50
+ the original version of the Work and any modifications or additions
51
+ to that Work or Derivative Works thereof, that is intentionally
52
+ submitted to Licensor for inclusion in the Work by the copyright owner
53
+ or by an individual or Legal Entity authorized to submit on behalf of
54
+ the copyright owner. For the purposes of this definition, "submitted"
55
+ means any form of electronic, verbal, or written communication sent
56
+ to the Licensor or its representatives, including but not limited to
57
+ communication on electronic mailing lists, source code control systems,
58
+ and issue tracking systems that are managed by, or on behalf of, the
59
+ Licensor for the purpose of discussing and improving the Work, but
60
+ excluding communication that is conspicuously marked or otherwise
61
+ designated in writing by the copyright owner as "Not a Contribution."
62
+
63
+ "Contributor" shall mean Licensor and any individual or Legal Entity
64
+ on behalf of whom a Contribution has been received by Licensor and
65
+ subsequently incorporated within the Work.
66
+
67
+ 2. Grant of Copyright License. Subject to the terms and conditions of
68
+ this License, each Contributor hereby grants to You a perpetual,
69
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
70
+ copyright license to reproduce, prepare Derivative Works of,
71
+ publicly display, publicly perform, sublicense, and distribute the
72
+ Work and such Derivative Works in Source or Object form.
73
+
74
+ 3. Grant of Patent License. Subject to the terms and conditions of
75
+ this License, each Contributor hereby grants to You a perpetual,
76
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
77
+ (except as stated in this section) patent license to make, have made,
78
+ use, offer to sell, sell, import, and otherwise transfer the Work,
79
+ where such license applies only to those patent claims licensable
80
+ by such Contributor that are necessarily infringed by their
81
+ Contribution(s) alone or by combination of their Contribution(s)
82
+ with the Work to which such Contribution(s) was submitted. If You
83
+ institute patent litigation against any entity (including a
84
+ cross-claim or counterclaim in a lawsuit) alleging that the Work
85
+ or a Contribution incorporated within the Work constitutes direct
86
+ or contributory patent infringement, then any patent licenses
87
+ granted to You under this License for that Work shall terminate
88
+ as of the date such litigation is filed.
89
+
90
+ 4. Redistribution. You may reproduce and distribute copies of the
91
+ Work or Derivative Works thereof in any medium, with or without
92
+ modifications, and in Source or Object form, provided that You
93
+ meet the following conditions:
94
+
95
+ (a) You must give any other recipients of the Work or
96
+ Derivative Works a copy of this License; and
97
+
98
+ (b) You must cause any modified files to carry prominent notices
99
+ stating that You changed the files; and
100
+
101
+ (c) You must retain, in the Source form of any Derivative Works
102
+ that You distribute, all copyright, patent, trademark, and
103
+ attribution notices from the Source form of the Work,
104
+ excluding those notices that do not pertain to any part of
105
+ the Derivative Works; and
106
+
107
+ (d) If the Work includes a "NOTICE" text file as part of its
108
+ distribution, then any Derivative Works that You distribute must
109
+ include a readable copy of the attribution notices contained
110
+ within such NOTICE file, excluding those notices that do not
111
+ pertain to any part of the Derivative Works, in at least one
112
+ of the following places: within a NOTICE text file distributed
113
+ as part of the Derivative Works; within the Source form or
114
+ documentation, if provided along with the Derivative Works; or,
115
+ within a display generated by the Derivative Works, if and
116
+ wherever such third-party notices normally appear. The contents
117
+ of the NOTICE file are for informational purposes only and
118
+ do not modify the License. You may add Your own attribution
119
+ notices within Derivative Works that You distribute, alongside
120
+ or as an addendum to the NOTICE text from the Work, provided
121
+ that such additional attribution notices cannot be construed
122
+ as modifying the License.
123
+
124
+ You may add Your own copyright statement to Your modifications and
125
+ may provide additional or different license terms and conditions
126
+ for use, reproduction, or distribution of Your modifications, or
127
+ for any such Derivative Works as a whole, provided Your use,
128
+ reproduction, and distribution of the Work otherwise complies with
129
+ the conditions stated in this License.
130
+
131
+ 5. Submission of Contributions. Unless You explicitly state otherwise,
132
+ any Contribution intentionally submitted for inclusion in the Work
133
+ by You to the Licensor shall be under the terms and conditions of
134
+ this License, without any additional terms or conditions.
135
+ Notwithstanding the above, nothing herein shall supersede or modify
136
+ the terms of any separate license agreement you may have executed
137
+ with Licensor regarding such Contributions.
138
+
139
+ 6. Trademarks. This License does not grant permission to use the trade
140
+ names, trademarks, service marks, or product names of the Licensor,
141
+ except as required for reasonable and customary use in describing the
142
+ origin of the Work and reproducing the content of the NOTICE file.
143
+
144
+ 7. Disclaimer of Warranty. Unless required by applicable law or
145
+ agreed to in writing, Licensor provides the Work (and each
146
+ Contributor provides its Contributions) on an "AS IS" BASIS,
147
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
148
+ implied, including, without limitation, any warranties or conditions
149
+ of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
150
+ PARTICULAR PURPOSE. You are solely responsible for determining the
151
+ appropriateness of using or redistributing the Work and assume any
152
+ risks associated with Your exercise of permissions under this License.
153
+
154
+ 8. Limitation of Liability. In no event and under no legal theory,
155
+ whether in tort (including negligence), contract, or otherwise,
156
+ unless required by applicable law (such as deliberate and grossly
157
+ negligent acts) or agreed to in writing, shall any Contributor be
158
+ liable to You for damages, including any direct, indirect, special,
159
+ incidental, or consequential damages of any character arising as a
160
+ result of this License or out of the use or inability to use the
161
+ Work (including but not limited to damages for loss of goodwill,
162
+ work stoppage, computer failure or malfunction, or any and all
163
+ other commercial damages or losses), even if such Contributor
164
+ has been advised of the possibility of such damages.
165
+
166
+ 9. Accepting Warranty or Additional Liability. While redistributing
167
+ the Work or Derivative Works thereof, You may choose to offer,
168
+ and charge a fee for, acceptance of support, warranty, indemnity,
169
+ or other liability obligations and/or rights consistent with this
170
+ License. However, in accepting such obligations, You may act only
171
+ on Your own behalf and on Your sole responsibility, not on behalf
172
+ of any other Contributor, and only if You agree to indemnify,
173
+ defend, and hold each Contributor harmless for any liability
174
+ incurred by, or claims asserted against, such Contributor by reason
175
+ of your accepting any such warranty or additional liability.
176
+
177
+ END OF TERMS AND CONDITIONS
178
+
179
+ APPENDIX: How to apply the Apache License to your work.
180
+
181
+ To apply the Apache License to your work, attach the following
182
+ boilerplate notice, with the fields enclosed by brackets "[]"
183
+ replaced with your own identifying information. (Don't include
184
+ the brackets!) The text should be enclosed in the appropriate
185
+ comment syntax for the file format. We also recommend that a
186
+ file or class name and description of purpose be included on the
187
+ same "printed page" as the copyright notice for easier
188
+ identification within third-party archives.
189
+
190
+ Copyright [yyyy] [name of copyright owner]
191
+
192
+ Licensed under the Apache License, Version 2.0 (the "License");
193
+ you may not use this file except in compliance with the License.
194
+ You may obtain a copy of the License at
195
+
196
+ http://www.apache.org/licenses/LICENSE-2.0
197
+
198
+ Unless required by applicable law or agreed to in writing, software
199
+ distributed under the License is distributed on an "AS IS" BASIS,
200
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
201
+ See the License for the specific language governing permissions and
202
+ limitations under the License.
.venv/Lib/site-packages/setuptools/_vendor/importlib_metadata-8.0.0.dist-info/METADATA ADDED
@@ -0,0 +1,129 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ Metadata-Version: 2.1
2
+ Name: importlib_metadata
3
+ Version: 8.0.0
4
+ Summary: Read metadata from Python packages
5
+ Author-email: "Jason R. Coombs" <jaraco@jaraco.com>
6
+ Project-URL: Source, https://github.com/python/importlib_metadata
7
+ Classifier: Development Status :: 5 - Production/Stable
8
+ Classifier: Intended Audience :: Developers
9
+ Classifier: License :: OSI Approved :: Apache Software License
10
+ Classifier: Programming Language :: Python :: 3
11
+ Classifier: Programming Language :: Python :: 3 :: Only
12
+ Requires-Python: >=3.8
13
+ Description-Content-Type: text/x-rst
14
+ License-File: LICENSE
15
+ Requires-Dist: zipp >=0.5
16
+ Requires-Dist: typing-extensions >=3.6.4 ; python_version < "3.8"
17
+ Provides-Extra: doc
18
+ Requires-Dist: sphinx >=3.5 ; extra == 'doc'
19
+ Requires-Dist: jaraco.packaging >=9.3 ; extra == 'doc'
20
+ Requires-Dist: rst.linker >=1.9 ; extra == 'doc'
21
+ Requires-Dist: furo ; extra == 'doc'
22
+ Requires-Dist: sphinx-lint ; extra == 'doc'
23
+ Requires-Dist: jaraco.tidelift >=1.4 ; extra == 'doc'
24
+ Provides-Extra: perf
25
+ Requires-Dist: ipython ; extra == 'perf'
26
+ Provides-Extra: test
27
+ Requires-Dist: pytest !=8.1.*,>=6 ; extra == 'test'
28
+ Requires-Dist: pytest-checkdocs >=2.4 ; extra == 'test'
29
+ Requires-Dist: pytest-cov ; extra == 'test'
30
+ Requires-Dist: pytest-mypy ; extra == 'test'
31
+ Requires-Dist: pytest-enabler >=2.2 ; extra == 'test'
32
+ Requires-Dist: pytest-ruff >=0.2.1 ; extra == 'test'
33
+ Requires-Dist: packaging ; extra == 'test'
34
+ Requires-Dist: pyfakefs ; extra == 'test'
35
+ Requires-Dist: flufl.flake8 ; extra == 'test'
36
+ Requires-Dist: pytest-perf >=0.9.2 ; extra == 'test'
37
+ Requires-Dist: jaraco.test >=5.4 ; extra == 'test'
38
+ Requires-Dist: importlib-resources >=1.3 ; (python_version < "3.9") and extra == 'test'
39
+
40
+ .. image:: https://img.shields.io/pypi/v/importlib_metadata.svg
41
+ :target: https://pypi.org/project/importlib_metadata
42
+
43
+ .. image:: https://img.shields.io/pypi/pyversions/importlib_metadata.svg
44
+
45
+ .. image:: https://github.com/python/importlib_metadata/actions/workflows/main.yml/badge.svg
46
+ :target: https://github.com/python/importlib_metadata/actions?query=workflow%3A%22tests%22
47
+ :alt: tests
48
+
49
+ .. image:: https://img.shields.io/endpoint?url=https://raw.githubusercontent.com/charliermarsh/ruff/main/assets/badge/v2.json
50
+ :target: https://github.com/astral-sh/ruff
51
+ :alt: Ruff
52
+
53
+ .. image:: https://readthedocs.org/projects/importlib-metadata/badge/?version=latest
54
+ :target: https://importlib-metadata.readthedocs.io/en/latest/?badge=latest
55
+
56
+ .. image:: https://img.shields.io/badge/skeleton-2024-informational
57
+ :target: https://blog.jaraco.com/skeleton
58
+
59
+ .. image:: https://tidelift.com/badges/package/pypi/importlib-metadata
60
+ :target: https://tidelift.com/subscription/pkg/pypi-importlib-metadata?utm_source=pypi-importlib-metadata&utm_medium=readme
61
+
62
+ Library to access the metadata for a Python package.
63
+
64
+ This package supplies third-party access to the functionality of
65
+ `importlib.metadata <https://docs.python.org/3/library/importlib.metadata.html>`_
66
+ including improvements added to subsequent Python versions.
67
+
68
+
69
+ Compatibility
70
+ =============
71
+
72
+ New features are introduced in this third-party library and later merged
73
+ into CPython. The following table indicates which versions of this library
74
+ were contributed to different versions in the standard library:
75
+
76
+ .. list-table::
77
+ :header-rows: 1
78
+
79
+ * - importlib_metadata
80
+ - stdlib
81
+ * - 7.0
82
+ - 3.13
83
+ * - 6.5
84
+ - 3.12
85
+ * - 4.13
86
+ - 3.11
87
+ * - 4.6
88
+ - 3.10
89
+ * - 1.4
90
+ - 3.8
91
+
92
+
93
+ Usage
94
+ =====
95
+
96
+ See the `online documentation <https://importlib-metadata.readthedocs.io/>`_
97
+ for usage details.
98
+
99
+ `Finder authors
100
+ <https://docs.python.org/3/reference/import.html#finders-and-loaders>`_ can
101
+ also add support for custom package installers. See the above documentation
102
+ for details.
103
+
104
+
105
+ Caveats
106
+ =======
107
+
108
+ This project primarily supports third-party packages installed by PyPA
109
+ tools (or other conforming packages). It does not support:
110
+
111
+ - Packages in the stdlib.
112
+ - Packages installed without metadata.
113
+
114
+ Project details
115
+ ===============
116
+
117
+ * Project home: https://github.com/python/importlib_metadata
118
+ * Report bugs at: https://github.com/python/importlib_metadata/issues
119
+ * Code hosting: https://github.com/python/importlib_metadata
120
+ * Documentation: https://importlib-metadata.readthedocs.io/
121
+
122
+ For Enterprise
123
+ ==============
124
+
125
+ Available as part of the Tidelift Subscription.
126
+
127
+ This project and the maintainers of thousands of other packages are working with Tidelift to deliver one enterprise subscription that covers all of the open source you use.
128
+
129
+ `Learn more <https://tidelift.com/subscription/pkg/pypi-importlib-metadata?utm_source=pypi-importlib-metadata&utm_medium=referral&utm_campaign=github>`_.
.venv/Lib/site-packages/setuptools/_vendor/importlib_metadata-8.0.0.dist-info/RECORD ADDED
@@ -0,0 +1,32 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ importlib_metadata-8.0.0.dist-info/INSTALLER,sha256=zuuue4knoyJ-UwPPXg8fezS7VCrXJQrAP7zeNuwvFQg,4
2
+ importlib_metadata-8.0.0.dist-info/LICENSE,sha256=z8d0m5b2O9McPEK1xHG_dWgUBT6EfBDz6wA0F7xSPTA,11358
3
+ importlib_metadata-8.0.0.dist-info/METADATA,sha256=anuQ7_7h4J1bSEzfcjIBakPi2cyVQ7y7jklLHsBeH1k,4648
4
+ importlib_metadata-8.0.0.dist-info/RECORD,,
5
+ importlib_metadata-8.0.0.dist-info/REQUESTED,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
6
+ importlib_metadata-8.0.0.dist-info/WHEEL,sha256=mguMlWGMX-VHnMpKOjjQidIo1ssRlCFu4a4mBpz1s2M,91
7
+ importlib_metadata-8.0.0.dist-info/top_level.txt,sha256=CO3fD9yylANiXkrMo4qHLV_mqXL2sC5JFKgt1yWAT-A,19
8
+ importlib_metadata/__init__.py,sha256=tZNB-23h8Bixi9uCrQqj9Yf0aeC--Josdy3IZRIQeB0,33798
9
+ importlib_metadata/__pycache__/__init__.cpython-312.pyc,,
10
+ importlib_metadata/__pycache__/_adapters.cpython-312.pyc,,
11
+ importlib_metadata/__pycache__/_collections.cpython-312.pyc,,
12
+ importlib_metadata/__pycache__/_compat.cpython-312.pyc,,
13
+ importlib_metadata/__pycache__/_functools.cpython-312.pyc,,
14
+ importlib_metadata/__pycache__/_itertools.cpython-312.pyc,,
15
+ importlib_metadata/__pycache__/_meta.cpython-312.pyc,,
16
+ importlib_metadata/__pycache__/_text.cpython-312.pyc,,
17
+ importlib_metadata/__pycache__/diagnose.cpython-312.pyc,,
18
+ importlib_metadata/_adapters.py,sha256=rIhWTwBvYA1bV7i-5FfVX38qEXDTXFeS5cb5xJtP3ks,2317
19
+ importlib_metadata/_collections.py,sha256=CJ0OTCHIjWA0ZIVS4voORAsn2R4R2cQBEtPsZEJpASY,743
20
+ importlib_metadata/_compat.py,sha256=73QKrN9KNoaZzhbX5yPCCZa-FaALwXe8TPlDR72JgBU,1314
21
+ importlib_metadata/_functools.py,sha256=PsY2-4rrKX4RVeRC1oGp1lB1pmC9eKN88_f-bD9uOoA,2895
22
+ importlib_metadata/_itertools.py,sha256=cvr_2v8BRbxcIl5x5ldfqdHjhI8Yi8s8yk50G_nm6jQ,2068
23
+ importlib_metadata/_meta.py,sha256=nxZ7C8GVlcBFAKWyVOn_dn7ot_twBcbm1NmvjIetBHI,1801
24
+ importlib_metadata/_text.py,sha256=HCsFksZpJLeTP3NEk_ngrAeXVRRtTrtyh9eOABoRP4A,2166
25
+ importlib_metadata/compat/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
26
+ importlib_metadata/compat/__pycache__/__init__.cpython-312.pyc,,
27
+ importlib_metadata/compat/__pycache__/py311.cpython-312.pyc,,
28
+ importlib_metadata/compat/__pycache__/py39.cpython-312.pyc,,
29
+ importlib_metadata/compat/py311.py,sha256=uqm-K-uohyj1042TH4a9Er_I5o7667DvulcD-gC_fSA,608
30
+ importlib_metadata/compat/py39.py,sha256=cPkMv6-0ilK-0Jw_Tkn0xYbOKJZc4WJKQHow0c2T44w,1102
31
+ importlib_metadata/diagnose.py,sha256=nkSRMiowlmkhLYhKhvCg9glmt_11Cox-EmLzEbqYTa8,379
32
+ importlib_metadata/py.typed,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
.venv/Lib/site-packages/setuptools/_vendor/importlib_metadata-8.0.0.dist-info/REQUESTED ADDED
File without changes
.venv/Lib/site-packages/setuptools/_vendor/importlib_metadata-8.0.0.dist-info/WHEEL ADDED
@@ -0,0 +1,5 @@
 
 
 
 
 
 
1
+ Wheel-Version: 1.0
2
+ Generator: setuptools (70.1.1)
3
+ Root-Is-Purelib: true
4
+ Tag: py3-none-any
5
+
.venv/Lib/site-packages/setuptools/_vendor/importlib_metadata-8.0.0.dist-info/top_level.txt ADDED
@@ -0,0 +1 @@
 
 
1
+ importlib_metadata
.venv/Lib/site-packages/setuptools/_vendor/importlib_metadata/__init__.py ADDED
@@ -0,0 +1,1083 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ from __future__ import annotations
2
+
3
+ import os
4
+ import re
5
+ import abc
6
+ import sys
7
+ import json
8
+ import zipp
9
+ import email
10
+ import types
11
+ import inspect
12
+ import pathlib
13
+ import operator
14
+ import textwrap
15
+ import functools
16
+ import itertools
17
+ import posixpath
18
+ import collections
19
+
20
+ from . import _meta
21
+ from .compat import py39, py311
22
+ from ._collections import FreezableDefaultDict, Pair
23
+ from ._compat import (
24
+ NullFinder,
25
+ install,
26
+ )
27
+ from ._functools import method_cache, pass_none
28
+ from ._itertools import always_iterable, unique_everseen
29
+ from ._meta import PackageMetadata, SimplePath
30
+
31
+ from contextlib import suppress
32
+ from importlib import import_module
33
+ from importlib.abc import MetaPathFinder
34
+ from itertools import starmap
35
+ from typing import Any, Iterable, List, Mapping, Match, Optional, Set, cast
36
+
37
+ __all__ = [
38
+ 'Distribution',
39
+ 'DistributionFinder',
40
+ 'PackageMetadata',
41
+ 'PackageNotFoundError',
42
+ 'distribution',
43
+ 'distributions',
44
+ 'entry_points',
45
+ 'files',
46
+ 'metadata',
47
+ 'packages_distributions',
48
+ 'requires',
49
+ 'version',
50
+ ]
51
+
52
+
53
+ class PackageNotFoundError(ModuleNotFoundError):
54
+ """The package was not found."""
55
+
56
+ def __str__(self) -> str:
57
+ return f"No package metadata was found for {self.name}"
58
+
59
+ @property
60
+ def name(self) -> str: # type: ignore[override]
61
+ (name,) = self.args
62
+ return name
63
+
64
+
65
+ class Sectioned:
66
+ """
67
+ A simple entry point config parser for performance
68
+
69
+ >>> for item in Sectioned.read(Sectioned._sample):
70
+ ... print(item)
71
+ Pair(name='sec1', value='# comments ignored')
72
+ Pair(name='sec1', value='a = 1')
73
+ Pair(name='sec1', value='b = 2')
74
+ Pair(name='sec2', value='a = 2')
75
+
76
+ >>> res = Sectioned.section_pairs(Sectioned._sample)
77
+ >>> item = next(res)
78
+ >>> item.name
79
+ 'sec1'
80
+ >>> item.value
81
+ Pair(name='a', value='1')
82
+ >>> item = next(res)
83
+ >>> item.value
84
+ Pair(name='b', value='2')
85
+ >>> item = next(res)
86
+ >>> item.name
87
+ 'sec2'
88
+ >>> item.value
89
+ Pair(name='a', value='2')
90
+ >>> list(res)
91
+ []
92
+ """
93
+
94
+ _sample = textwrap.dedent(
95
+ """
96
+ [sec1]
97
+ # comments ignored
98
+ a = 1
99
+ b = 2
100
+
101
+ [sec2]
102
+ a = 2
103
+ """
104
+ ).lstrip()
105
+
106
+ @classmethod
107
+ def section_pairs(cls, text):
108
+ return (
109
+ section._replace(value=Pair.parse(section.value))
110
+ for section in cls.read(text, filter_=cls.valid)
111
+ if section.name is not None
112
+ )
113
+
114
+ @staticmethod
115
+ def read(text, filter_=None):
116
+ lines = filter(filter_, map(str.strip, text.splitlines()))
117
+ name = None
118
+ for value in lines:
119
+ section_match = value.startswith('[') and value.endswith(']')
120
+ if section_match:
121
+ name = value.strip('[]')
122
+ continue
123
+ yield Pair(name, value)
124
+
125
+ @staticmethod
126
+ def valid(line: str):
127
+ return line and not line.startswith('#')
128
+
129
+
130
+ class EntryPoint:
131
+ """An entry point as defined by Python packaging conventions.
132
+
133
+ See `the packaging docs on entry points
134
+ <https://packaging.python.org/specifications/entry-points/>`_
135
+ for more information.
136
+
137
+ >>> ep = EntryPoint(
138
+ ... name=None, group=None, value='package.module:attr [extra1, extra2]')
139
+ >>> ep.module
140
+ 'package.module'
141
+ >>> ep.attr
142
+ 'attr'
143
+ >>> ep.extras
144
+ ['extra1', 'extra2']
145
+ """
146
+
147
+ pattern = re.compile(
148
+ r'(?P<module>[\w.]+)\s*'
149
+ r'(:\s*(?P<attr>[\w.]+)\s*)?'
150
+ r'((?P<extras>\[.*\])\s*)?$'
151
+ )
152
+ """
153
+ A regular expression describing the syntax for an entry point,
154
+ which might look like:
155
+
156
+ - module
157
+ - package.module
158
+ - package.module:attribute
159
+ - package.module:object.attribute
160
+ - package.module:attr [extra1, extra2]
161
+
162
+ Other combinations are possible as well.
163
+
164
+ The expression is lenient about whitespace around the ':',
165
+ following the attr, and following any extras.
166
+ """
167
+
168
+ name: str
169
+ value: str
170
+ group: str
171
+
172
+ dist: Optional[Distribution] = None
173
+
174
+ def __init__(self, name: str, value: str, group: str) -> None:
175
+ vars(self).update(name=name, value=value, group=group)
176
+
177
+ def load(self) -> Any:
178
+ """Load the entry point from its definition. If only a module
179
+ is indicated by the value, return that module. Otherwise,
180
+ return the named object.
181
+ """
182
+ match = cast(Match, self.pattern.match(self.value))
183
+ module = import_module(match.group('module'))
184
+ attrs = filter(None, (match.group('attr') or '').split('.'))
185
+ return functools.reduce(getattr, attrs, module)
186
+
187
+ @property
188
+ def module(self) -> str:
189
+ match = self.pattern.match(self.value)
190
+ assert match is not None
191
+ return match.group('module')
192
+
193
+ @property
194
+ def attr(self) -> str:
195
+ match = self.pattern.match(self.value)
196
+ assert match is not None
197
+ return match.group('attr')
198
+
199
+ @property
200
+ def extras(self) -> List[str]:
201
+ match = self.pattern.match(self.value)
202
+ assert match is not None
203
+ return re.findall(r'\w+', match.group('extras') or '')
204
+
205
+ def _for(self, dist):
206
+ vars(self).update(dist=dist)
207
+ return self
208
+
209
+ def matches(self, **params):
210
+ """
211
+ EntryPoint matches the given parameters.
212
+
213
+ >>> ep = EntryPoint(group='foo', name='bar', value='bing:bong [extra1, extra2]')
214
+ >>> ep.matches(group='foo')
215
+ True
216
+ >>> ep.matches(name='bar', value='bing:bong [extra1, extra2]')
217
+ True
218
+ >>> ep.matches(group='foo', name='other')
219
+ False
220
+ >>> ep.matches()
221
+ True
222
+ >>> ep.matches(extras=['extra1', 'extra2'])
223
+ True
224
+ >>> ep.matches(module='bing')
225
+ True
226
+ >>> ep.matches(attr='bong')
227
+ True
228
+ """
229
+ attrs = (getattr(self, param) for param in params)
230
+ return all(map(operator.eq, params.values(), attrs))
231
+
232
+ def _key(self):
233
+ return self.name, self.value, self.group
234
+
235
+ def __lt__(self, other):
236
+ return self._key() < other._key()
237
+
238
+ def __eq__(self, other):
239
+ return self._key() == other._key()
240
+
241
+ def __setattr__(self, name, value):
242
+ raise AttributeError("EntryPoint objects are immutable.")
243
+
244
+ def __repr__(self):
245
+ return (
246
+ f'EntryPoint(name={self.name!r}, value={self.value!r}, '
247
+ f'group={self.group!r})'
248
+ )
249
+
250
+ def __hash__(self) -> int:
251
+ return hash(self._key())
252
+
253
+
254
+ class EntryPoints(tuple):
255
+ """
256
+ An immutable collection of selectable EntryPoint objects.
257
+ """
258
+
259
+ __slots__ = ()
260
+
261
+ def __getitem__(self, name: str) -> EntryPoint: # type: ignore[override]
262
+ """
263
+ Get the EntryPoint in self matching name.
264
+ """
265
+ try:
266
+ return next(iter(self.select(name=name)))
267
+ except StopIteration:
268
+ raise KeyError(name)
269
+
270
+ def __repr__(self):
271
+ """
272
+ Repr with classname and tuple constructor to
273
+ signal that we deviate from regular tuple behavior.
274
+ """
275
+ return '%s(%r)' % (self.__class__.__name__, tuple(self))
276
+
277
+ def select(self, **params) -> EntryPoints:
278
+ """
279
+ Select entry points from self that match the
280
+ given parameters (typically group and/or name).
281
+ """
282
+ return EntryPoints(ep for ep in self if py39.ep_matches(ep, **params))
283
+
284
+ @property
285
+ def names(self) -> Set[str]:
286
+ """
287
+ Return the set of all names of all entry points.
288
+ """
289
+ return {ep.name for ep in self}
290
+
291
+ @property
292
+ def groups(self) -> Set[str]:
293
+ """
294
+ Return the set of all groups of all entry points.
295
+ """
296
+ return {ep.group for ep in self}
297
+
298
+ @classmethod
299
+ def _from_text_for(cls, text, dist):
300
+ return cls(ep._for(dist) for ep in cls._from_text(text))
301
+
302
+ @staticmethod
303
+ def _from_text(text):
304
+ return (
305
+ EntryPoint(name=item.value.name, value=item.value.value, group=item.name)
306
+ for item in Sectioned.section_pairs(text or '')
307
+ )
308
+
309
+
310
+ class PackagePath(pathlib.PurePosixPath):
311
+ """A reference to a path in a package"""
312
+
313
+ hash: Optional[FileHash]
314
+ size: int
315
+ dist: Distribution
316
+
317
+ def read_text(self, encoding: str = 'utf-8') -> str: # type: ignore[override]
318
+ return self.locate().read_text(encoding=encoding)
319
+
320
+ def read_binary(self) -> bytes:
321
+ return self.locate().read_bytes()
322
+
323
+ def locate(self) -> SimplePath:
324
+ """Return a path-like object for this path"""
325
+ return self.dist.locate_file(self)
326
+
327
+
328
+ class FileHash:
329
+ def __init__(self, spec: str) -> None:
330
+ self.mode, _, self.value = spec.partition('=')
331
+
332
+ def __repr__(self) -> str:
333
+ return f'<FileHash mode: {self.mode} value: {self.value}>'
334
+
335
+
336
+ class Distribution(metaclass=abc.ABCMeta):
337
+ """
338
+ An abstract Python distribution package.
339
+
340
+ Custom providers may derive from this class and define
341
+ the abstract methods to provide a concrete implementation
342
+ for their environment. Some providers may opt to override
343
+ the default implementation of some properties to bypass
344
+ the file-reading mechanism.
345
+ """
346
+
347
+ @abc.abstractmethod
348
+ def read_text(self, filename) -> Optional[str]:
349
+ """Attempt to load metadata file given by the name.
350
+
351
+ Python distribution metadata is organized by blobs of text
352
+ typically represented as "files" in the metadata directory
353
+ (e.g. package-1.0.dist-info). These files include things
354
+ like:
355
+
356
+ - METADATA: The distribution metadata including fields
357
+ like Name and Version and Description.
358
+ - entry_points.txt: A series of entry points as defined in
359
+ `the entry points spec <https://packaging.python.org/en/latest/specifications/entry-points/#file-format>`_.
360
+ - RECORD: A record of files according to
361
+ `this recording spec <https://packaging.python.org/en/latest/specifications/recording-installed-packages/#the-record-file>`_.
362
+
363
+ A package may provide any set of files, including those
364
+ not listed here or none at all.
365
+
366
+ :param filename: The name of the file in the distribution info.
367
+ :return: The text if found, otherwise None.
368
+ """
369
+
370
+ @abc.abstractmethod
371
+ def locate_file(self, path: str | os.PathLike[str]) -> SimplePath:
372
+ """
373
+ Given a path to a file in this distribution, return a SimplePath
374
+ to it.
375
+ """
376
+
377
+ @classmethod
378
+ def from_name(cls, name: str) -> Distribution:
379
+ """Return the Distribution for the given package name.
380
+
381
+ :param name: The name of the distribution package to search for.
382
+ :return: The Distribution instance (or subclass thereof) for the named
383
+ package, if found.
384
+ :raises PackageNotFoundError: When the named package's distribution
385
+ metadata cannot be found.
386
+ :raises ValueError: When an invalid value is supplied for name.
387
+ """
388
+ if not name:
389
+ raise ValueError("A distribution name is required.")
390
+ try:
391
+ return next(iter(cls.discover(name=name)))
392
+ except StopIteration:
393
+ raise PackageNotFoundError(name)
394
+
395
+ @classmethod
396
+ def discover(
397
+ cls, *, context: Optional[DistributionFinder.Context] = None, **kwargs
398
+ ) -> Iterable[Distribution]:
399
+ """Return an iterable of Distribution objects for all packages.
400
+
401
+ Pass a ``context`` or pass keyword arguments for constructing
402
+ a context.
403
+
404
+ :context: A ``DistributionFinder.Context`` object.
405
+ :return: Iterable of Distribution objects for packages matching
406
+ the context.
407
+ """
408
+ if context and kwargs:
409
+ raise ValueError("cannot accept context and kwargs")
410
+ context = context or DistributionFinder.Context(**kwargs)
411
+ return itertools.chain.from_iterable(
412
+ resolver(context) for resolver in cls._discover_resolvers()
413
+ )
414
+
415
+ @staticmethod
416
+ def at(path: str | os.PathLike[str]) -> Distribution:
417
+ """Return a Distribution for the indicated metadata path.
418
+
419
+ :param path: a string or path-like object
420
+ :return: a concrete Distribution instance for the path
421
+ """
422
+ return PathDistribution(pathlib.Path(path))
423
+
424
+ @staticmethod
425
+ def _discover_resolvers():
426
+ """Search the meta_path for resolvers (MetadataPathFinders)."""
427
+ declared = (
428
+ getattr(finder, 'find_distributions', None) for finder in sys.meta_path
429
+ )
430
+ return filter(None, declared)
431
+
432
+ @property
433
+ def metadata(self) -> _meta.PackageMetadata:
434
+ """Return the parsed metadata for this Distribution.
435
+
436
+ The returned object will have keys that name the various bits of
437
+ metadata per the
438
+ `Core metadata specifications <https://packaging.python.org/en/latest/specifications/core-metadata/#core-metadata>`_.
439
+
440
+ Custom providers may provide the METADATA file or override this
441
+ property.
442
+ """
443
+ # deferred for performance (python/cpython#109829)
444
+ from . import _adapters
445
+
446
+ opt_text = (
447
+ self.read_text('METADATA')
448
+ or self.read_text('PKG-INFO')
449
+ # This last clause is here to support old egg-info files. Its
450
+ # effect is to just end up using the PathDistribution's self._path
451
+ # (which points to the egg-info file) attribute unchanged.
452
+ or self.read_text('')
453
+ )
454
+ text = cast(str, opt_text)
455
+ return _adapters.Message(email.message_from_string(text))
456
+
457
+ @property
458
+ def name(self) -> str:
459
+ """Return the 'Name' metadata for the distribution package."""
460
+ return self.metadata['Name']
461
+
462
+ @property
463
+ def _normalized_name(self):
464
+ """Return a normalized version of the name."""
465
+ return Prepared.normalize(self.name)
466
+
467
+ @property
468
+ def version(self) -> str:
469
+ """Return the 'Version' metadata for the distribution package."""
470
+ return self.metadata['Version']
471
+
472
+ @property
473
+ def entry_points(self) -> EntryPoints:
474
+ """
475
+ Return EntryPoints for this distribution.
476
+
477
+ Custom providers may provide the ``entry_points.txt`` file
478
+ or override this property.
479
+ """
480
+ return EntryPoints._from_text_for(self.read_text('entry_points.txt'), self)
481
+
482
+ @property
483
+ def files(self) -> Optional[List[PackagePath]]:
484
+ """Files in this distribution.
485
+
486
+ :return: List of PackagePath for this distribution or None
487
+
488
+ Result is `None` if the metadata file that enumerates files
489
+ (i.e. RECORD for dist-info, or installed-files.txt or
490
+ SOURCES.txt for egg-info) is missing.
491
+ Result may be empty if the metadata exists but is empty.
492
+
493
+ Custom providers are recommended to provide a "RECORD" file (in
494
+ ``read_text``) or override this property to allow for callers to be
495
+ able to resolve filenames provided by the package.
496
+ """
497
+
498
+ def make_file(name, hash=None, size_str=None):
499
+ result = PackagePath(name)
500
+ result.hash = FileHash(hash) if hash else None
501
+ result.size = int(size_str) if size_str else None
502
+ result.dist = self
503
+ return result
504
+
505
+ @pass_none
506
+ def make_files(lines):
507
+ # Delay csv import, since Distribution.files is not as widely used
508
+ # as other parts of importlib.metadata
509
+ import csv
510
+
511
+ return starmap(make_file, csv.reader(lines))
512
+
513
+ @pass_none
514
+ def skip_missing_files(package_paths):
515
+ return list(filter(lambda path: path.locate().exists(), package_paths))
516
+
517
+ return skip_missing_files(
518
+ make_files(
519
+ self._read_files_distinfo()
520
+ or self._read_files_egginfo_installed()
521
+ or self._read_files_egginfo_sources()
522
+ )
523
+ )
524
+
525
+ def _read_files_distinfo(self):
526
+ """
527
+ Read the lines of RECORD.
528
+ """
529
+ text = self.read_text('RECORD')
530
+ return text and text.splitlines()
531
+
532
+ def _read_files_egginfo_installed(self):
533
+ """
534
+ Read installed-files.txt and return lines in a similar
535
+ CSV-parsable format as RECORD: each file must be placed
536
+ relative to the site-packages directory and must also be
537
+ quoted (since file names can contain literal commas).
538
+
539
+ This file is written when the package is installed by pip,
540
+ but it might not be written for other installation methods.
541
+ Assume the file is accurate if it exists.
542
+ """
543
+ text = self.read_text('installed-files.txt')
544
+ # Prepend the .egg-info/ subdir to the lines in this file.
545
+ # But this subdir is only available from PathDistribution's
546
+ # self._path.
547
+ subdir = getattr(self, '_path', None)
548
+ if not text or not subdir:
549
+ return
550
+
551
+ paths = (
552
+ py311.relative_fix((subdir / name).resolve())
553
+ .relative_to(self.locate_file('').resolve(), walk_up=True)
554
+ .as_posix()
555
+ for name in text.splitlines()
556
+ )
557
+ return map('"{}"'.format, paths)
558
+
559
+ def _read_files_egginfo_sources(self):
560
+ """
561
+ Read SOURCES.txt and return lines in a similar CSV-parsable
562
+ format as RECORD: each file name must be quoted (since it
563
+ might contain literal commas).
564
+
565
+ Note that SOURCES.txt is not a reliable source for what
566
+ files are installed by a package. This file is generated
567
+ for a source archive, and the files that are present
568
+ there (e.g. setup.py) may not correctly reflect the files
569
+ that are present after the package has been installed.
570
+ """
571
+ text = self.read_text('SOURCES.txt')
572
+ return text and map('"{}"'.format, text.splitlines())
573
+
574
+ @property
575
+ def requires(self) -> Optional[List[str]]:
576
+ """Generated requirements specified for this Distribution"""
577
+ reqs = self._read_dist_info_reqs() or self._read_egg_info_reqs()
578
+ return reqs and list(reqs)
579
+
580
+ def _read_dist_info_reqs(self):
581
+ return self.metadata.get_all('Requires-Dist')
582
+
583
+ def _read_egg_info_reqs(self):
584
+ source = self.read_text('requires.txt')
585
+ return pass_none(self._deps_from_requires_text)(source)
586
+
587
+ @classmethod
588
+ def _deps_from_requires_text(cls, source):
589
+ return cls._convert_egg_info_reqs_to_simple_reqs(Sectioned.read(source))
590
+
591
+ @staticmethod
592
+ def _convert_egg_info_reqs_to_simple_reqs(sections):
593
+ """
594
+ Historically, setuptools would solicit and store 'extra'
595
+ requirements, including those with environment markers,
596
+ in separate sections. More modern tools expect each
597
+ dependency to be defined separately, with any relevant
598
+ extras and environment markers attached directly to that
599
+ requirement. This method converts the former to the
600
+ latter. See _test_deps_from_requires_text for an example.
601
+ """
602
+
603
+ def make_condition(name):
604
+ return name and f'extra == "{name}"'
605
+
606
+ def quoted_marker(section):
607
+ section = section or ''
608
+ extra, sep, markers = section.partition(':')
609
+ if extra and markers:
610
+ markers = f'({markers})'
611
+ conditions = list(filter(None, [markers, make_condition(extra)]))
612
+ return '; ' + ' and '.join(conditions) if conditions else ''
613
+
614
+ def url_req_space(req):
615
+ """
616
+ PEP 508 requires a space between the url_spec and the quoted_marker.
617
+ Ref python/importlib_metadata#357.
618
+ """
619
+ # '@' is uniquely indicative of a url_req.
620
+ return ' ' * ('@' in req)
621
+
622
+ for section in sections:
623
+ space = url_req_space(section.value)
624
+ yield section.value + space + quoted_marker(section.name)
625
+
626
+ @property
627
+ def origin(self):
628
+ return self._load_json('direct_url.json')
629
+
630
+ def _load_json(self, filename):
631
+ return pass_none(json.loads)(
632
+ self.read_text(filename),
633
+ object_hook=lambda data: types.SimpleNamespace(**data),
634
+ )
635
+
636
+
637
+ class DistributionFinder(MetaPathFinder):
638
+ """
639
+ A MetaPathFinder capable of discovering installed distributions.
640
+
641
+ Custom providers should implement this interface in order to
642
+ supply metadata.
643
+ """
644
+
645
+ class Context:
646
+ """
647
+ Keyword arguments presented by the caller to
648
+ ``distributions()`` or ``Distribution.discover()``
649
+ to narrow the scope of a search for distributions
650
+ in all DistributionFinders.
651
+
652
+ Each DistributionFinder may expect any parameters
653
+ and should attempt to honor the canonical
654
+ parameters defined below when appropriate.
655
+
656
+ This mechanism gives a custom provider a means to
657
+ solicit additional details from the caller beyond
658
+ "name" and "path" when searching distributions.
659
+ For example, imagine a provider that exposes suites
660
+ of packages in either a "public" or "private" ``realm``.
661
+ A caller may wish to query only for distributions in
662
+ a particular realm and could call
663
+ ``distributions(realm="private")`` to signal to the
664
+ custom provider to only include distributions from that
665
+ realm.
666
+ """
667
+
668
+ name = None
669
+ """
670
+ Specific name for which a distribution finder should match.
671
+ A name of ``None`` matches all distributions.
672
+ """
673
+
674
+ def __init__(self, **kwargs):
675
+ vars(self).update(kwargs)
676
+
677
+ @property
678
+ def path(self) -> List[str]:
679
+ """
680
+ The sequence of directory path that a distribution finder
681
+ should search.
682
+
683
+ Typically refers to Python installed package paths such as
684
+ "site-packages" directories and defaults to ``sys.path``.
685
+ """
686
+ return vars(self).get('path', sys.path)
687
+
688
+ @abc.abstractmethod
689
+ def find_distributions(self, context=Context()) -> Iterable[Distribution]:
690
+ """
691
+ Find distributions.
692
+
693
+ Return an iterable of all Distribution instances capable of
694
+ loading the metadata for packages matching the ``context``,
695
+ a DistributionFinder.Context instance.
696
+ """
697
+
698
+
699
+ class FastPath:
700
+ """
701
+ Micro-optimized class for searching a root for children.
702
+
703
+ Root is a path on the file system that may contain metadata
704
+ directories either as natural directories or within a zip file.
705
+
706
+ >>> FastPath('').children()
707
+ ['...']
708
+
709
+ FastPath objects are cached and recycled for any given root.
710
+
711
+ >>> FastPath('foobar') is FastPath('foobar')
712
+ True
713
+ """
714
+
715
+ @functools.lru_cache() # type: ignore
716
+ def __new__(cls, root):
717
+ return super().__new__(cls)
718
+
719
+ def __init__(self, root):
720
+ self.root = root
721
+
722
+ def joinpath(self, child):
723
+ return pathlib.Path(self.root, child)
724
+
725
+ def children(self):
726
+ with suppress(Exception):
727
+ return os.listdir(self.root or '.')
728
+ with suppress(Exception):
729
+ return self.zip_children()
730
+ return []
731
+
732
+ def zip_children(self):
733
+ zip_path = zipp.Path(self.root)
734
+ names = zip_path.root.namelist()
735
+ self.joinpath = zip_path.joinpath
736
+
737
+ return dict.fromkeys(child.split(posixpath.sep, 1)[0] for child in names)
738
+
739
+ def search(self, name):
740
+ return self.lookup(self.mtime).search(name)
741
+
742
+ @property
743
+ def mtime(self):
744
+ with suppress(OSError):
745
+ return os.stat(self.root).st_mtime
746
+ self.lookup.cache_clear()
747
+
748
+ @method_cache
749
+ def lookup(self, mtime):
750
+ return Lookup(self)
751
+
752
+
753
+ class Lookup:
754
+ """
755
+ A micro-optimized class for searching a (fast) path for metadata.
756
+ """
757
+
758
+ def __init__(self, path: FastPath):
759
+ """
760
+ Calculate all of the children representing metadata.
761
+
762
+ From the children in the path, calculate early all of the
763
+ children that appear to represent metadata (infos) or legacy
764
+ metadata (eggs).
765
+ """
766
+
767
+ base = os.path.basename(path.root).lower()
768
+ base_is_egg = base.endswith(".egg")
769
+ self.infos = FreezableDefaultDict(list)
770
+ self.eggs = FreezableDefaultDict(list)
771
+
772
+ for child in path.children():
773
+ low = child.lower()
774
+ if low.endswith((".dist-info", ".egg-info")):
775
+ # rpartition is faster than splitext and suitable for this purpose.
776
+ name = low.rpartition(".")[0].partition("-")[0]
777
+ normalized = Prepared.normalize(name)
778
+ self.infos[normalized].append(path.joinpath(child))
779
+ elif base_is_egg and low == "egg-info":
780
+ name = base.rpartition(".")[0].partition("-")[0]
781
+ legacy_normalized = Prepared.legacy_normalize(name)
782
+ self.eggs[legacy_normalized].append(path.joinpath(child))
783
+
784
+ self.infos.freeze()
785
+ self.eggs.freeze()
786
+
787
+ def search(self, prepared: Prepared):
788
+ """
789
+ Yield all infos and eggs matching the Prepared query.
790
+ """
791
+ infos = (
792
+ self.infos[prepared.normalized]
793
+ if prepared
794
+ else itertools.chain.from_iterable(self.infos.values())
795
+ )
796
+ eggs = (
797
+ self.eggs[prepared.legacy_normalized]
798
+ if prepared
799
+ else itertools.chain.from_iterable(self.eggs.values())
800
+ )
801
+ return itertools.chain(infos, eggs)
802
+
803
+
804
+ class Prepared:
805
+ """
806
+ A prepared search query for metadata on a possibly-named package.
807
+
808
+ Pre-calculates the normalization to prevent repeated operations.
809
+
810
+ >>> none = Prepared(None)
811
+ >>> none.normalized
812
+ >>> none.legacy_normalized
813
+ >>> bool(none)
814
+ False
815
+ >>> sample = Prepared('Sample__Pkg-name.foo')
816
+ >>> sample.normalized
817
+ 'sample_pkg_name_foo'
818
+ >>> sample.legacy_normalized
819
+ 'sample__pkg_name.foo'
820
+ >>> bool(sample)
821
+ True
822
+ """
823
+
824
+ normalized = None
825
+ legacy_normalized = None
826
+
827
+ def __init__(self, name: Optional[str]):
828
+ self.name = name
829
+ if name is None:
830
+ return
831
+ self.normalized = self.normalize(name)
832
+ self.legacy_normalized = self.legacy_normalize(name)
833
+
834
+ @staticmethod
835
+ def normalize(name):
836
+ """
837
+ PEP 503 normalization plus dashes as underscores.
838
+ """
839
+ return re.sub(r"[-_.]+", "-", name).lower().replace('-', '_')
840
+
841
+ @staticmethod
842
+ def legacy_normalize(name):
843
+ """
844
+ Normalize the package name as found in the convention in
845
+ older packaging tools versions and specs.
846
+ """
847
+ return name.lower().replace('-', '_')
848
+
849
+ def __bool__(self):
850
+ return bool(self.name)
851
+
852
+
853
+ @install
854
+ class MetadataPathFinder(NullFinder, DistributionFinder):
855
+ """A degenerate finder for distribution packages on the file system.
856
+
857
+ This finder supplies only a find_distributions() method for versions
858
+ of Python that do not have a PathFinder find_distributions().
859
+ """
860
+
861
+ @classmethod
862
+ def find_distributions(
863
+ cls, context=DistributionFinder.Context()
864
+ ) -> Iterable[PathDistribution]:
865
+ """
866
+ Find distributions.
867
+
868
+ Return an iterable of all Distribution instances capable of
869
+ loading the metadata for packages matching ``context.name``
870
+ (or all names if ``None`` indicated) along the paths in the list
871
+ of directories ``context.path``.
872
+ """
873
+ found = cls._search_paths(context.name, context.path)
874
+ return map(PathDistribution, found)
875
+
876
+ @classmethod
877
+ def _search_paths(cls, name, paths):
878
+ """Find metadata directories in paths heuristically."""
879
+ prepared = Prepared(name)
880
+ return itertools.chain.from_iterable(
881
+ path.search(prepared) for path in map(FastPath, paths)
882
+ )
883
+
884
+ @classmethod
885
+ def invalidate_caches(cls) -> None:
886
+ FastPath.__new__.cache_clear()
887
+
888
+
889
+ class PathDistribution(Distribution):
890
+ def __init__(self, path: SimplePath) -> None:
891
+ """Construct a distribution.
892
+
893
+ :param path: SimplePath indicating the metadata directory.
894
+ """
895
+ self._path = path
896
+
897
+ def read_text(self, filename: str | os.PathLike[str]) -> Optional[str]:
898
+ with suppress(
899
+ FileNotFoundError,
900
+ IsADirectoryError,
901
+ KeyError,
902
+ NotADirectoryError,
903
+ PermissionError,
904
+ ):
905
+ return self._path.joinpath(filename).read_text(encoding='utf-8')
906
+
907
+ return None
908
+
909
+ read_text.__doc__ = Distribution.read_text.__doc__
910
+
911
+ def locate_file(self, path: str | os.PathLike[str]) -> SimplePath:
912
+ return self._path.parent / path
913
+
914
+ @property
915
+ def _normalized_name(self):
916
+ """
917
+ Performance optimization: where possible, resolve the
918
+ normalized name from the file system path.
919
+ """
920
+ stem = os.path.basename(str(self._path))
921
+ return (
922
+ pass_none(Prepared.normalize)(self._name_from_stem(stem))
923
+ or super()._normalized_name
924
+ )
925
+
926
+ @staticmethod
927
+ def _name_from_stem(stem):
928
+ """
929
+ >>> PathDistribution._name_from_stem('foo-3.0.egg-info')
930
+ 'foo'
931
+ >>> PathDistribution._name_from_stem('CherryPy-3.0.dist-info')
932
+ 'CherryPy'
933
+ >>> PathDistribution._name_from_stem('face.egg-info')
934
+ 'face'
935
+ >>> PathDistribution._name_from_stem('foo.bar')
936
+ """
937
+ filename, ext = os.path.splitext(stem)
938
+ if ext not in ('.dist-info', '.egg-info'):
939
+ return
940
+ name, sep, rest = filename.partition('-')
941
+ return name
942
+
943
+
944
+ def distribution(distribution_name: str) -> Distribution:
945
+ """Get the ``Distribution`` instance for the named package.
946
+
947
+ :param distribution_name: The name of the distribution package as a string.
948
+ :return: A ``Distribution`` instance (or subclass thereof).
949
+ """
950
+ return Distribution.from_name(distribution_name)
951
+
952
+
953
+ def distributions(**kwargs) -> Iterable[Distribution]:
954
+ """Get all ``Distribution`` instances in the current environment.
955
+
956
+ :return: An iterable of ``Distribution`` instances.
957
+ """
958
+ return Distribution.discover(**kwargs)
959
+
960
+
961
+ def metadata(distribution_name: str) -> _meta.PackageMetadata:
962
+ """Get the metadata for the named package.
963
+
964
+ :param distribution_name: The name of the distribution package to query.
965
+ :return: A PackageMetadata containing the parsed metadata.
966
+ """
967
+ return Distribution.from_name(distribution_name).metadata
968
+
969
+
970
+ def version(distribution_name: str) -> str:
971
+ """Get the version string for the named package.
972
+
973
+ :param distribution_name: The name of the distribution package to query.
974
+ :return: The version string for the package as defined in the package's
975
+ "Version" metadata key.
976
+ """
977
+ return distribution(distribution_name).version
978
+
979
+
980
+ _unique = functools.partial(
981
+ unique_everseen,
982
+ key=py39.normalized_name,
983
+ )
984
+ """
985
+ Wrapper for ``distributions`` to return unique distributions by name.
986
+ """
987
+
988
+
989
+ def entry_points(**params) -> EntryPoints:
990
+ """Return EntryPoint objects for all installed packages.
991
+
992
+ Pass selection parameters (group or name) to filter the
993
+ result to entry points matching those properties (see
994
+ EntryPoints.select()).
995
+
996
+ :return: EntryPoints for all installed packages.
997
+ """
998
+ eps = itertools.chain.from_iterable(
999
+ dist.entry_points for dist in _unique(distributions())
1000
+ )
1001
+ return EntryPoints(eps).select(**params)
1002
+
1003
+
1004
+ def files(distribution_name: str) -> Optional[List[PackagePath]]:
1005
+ """Return a list of files for the named package.
1006
+
1007
+ :param distribution_name: The name of the distribution package to query.
1008
+ :return: List of files composing the distribution.
1009
+ """
1010
+ return distribution(distribution_name).files
1011
+
1012
+
1013
+ def requires(distribution_name: str) -> Optional[List[str]]:
1014
+ """
1015
+ Return a list of requirements for the named package.
1016
+
1017
+ :return: An iterable of requirements, suitable for
1018
+ packaging.requirement.Requirement.
1019
+ """
1020
+ return distribution(distribution_name).requires
1021
+
1022
+
1023
+ def packages_distributions() -> Mapping[str, List[str]]:
1024
+ """
1025
+ Return a mapping of top-level packages to their
1026
+ distributions.
1027
+
1028
+ >>> import collections.abc
1029
+ >>> pkgs = packages_distributions()
1030
+ >>> all(isinstance(dist, collections.abc.Sequence) for dist in pkgs.values())
1031
+ True
1032
+ """
1033
+ pkg_to_dist = collections.defaultdict(list)
1034
+ for dist in distributions():
1035
+ for pkg in _top_level_declared(dist) or _top_level_inferred(dist):
1036
+ pkg_to_dist[pkg].append(dist.metadata['Name'])
1037
+ return dict(pkg_to_dist)
1038
+
1039
+
1040
+ def _top_level_declared(dist):
1041
+ return (dist.read_text('top_level.txt') or '').split()
1042
+
1043
+
1044
+ def _topmost(name: PackagePath) -> Optional[str]:
1045
+ """
1046
+ Return the top-most parent as long as there is a parent.
1047
+ """
1048
+ top, *rest = name.parts
1049
+ return top if rest else None
1050
+
1051
+
1052
+ def _get_toplevel_name(name: PackagePath) -> str:
1053
+ """
1054
+ Infer a possibly importable module name from a name presumed on
1055
+ sys.path.
1056
+
1057
+ >>> _get_toplevel_name(PackagePath('foo.py'))
1058
+ 'foo'
1059
+ >>> _get_toplevel_name(PackagePath('foo'))
1060
+ 'foo'
1061
+ >>> _get_toplevel_name(PackagePath('foo.pyc'))
1062
+ 'foo'
1063
+ >>> _get_toplevel_name(PackagePath('foo/__init__.py'))
1064
+ 'foo'
1065
+ >>> _get_toplevel_name(PackagePath('foo.pth'))
1066
+ 'foo.pth'
1067
+ >>> _get_toplevel_name(PackagePath('foo.dist-info'))
1068
+ 'foo.dist-info'
1069
+ """
1070
+ return _topmost(name) or (
1071
+ # python/typeshed#10328
1072
+ inspect.getmodulename(name) # type: ignore
1073
+ or str(name)
1074
+ )
1075
+
1076
+
1077
+ def _top_level_inferred(dist):
1078
+ opt_names = set(map(_get_toplevel_name, always_iterable(dist.files)))
1079
+
1080
+ def importable_name(name):
1081
+ return '.' not in name
1082
+
1083
+ return filter(importable_name, opt_names)
.venv/Lib/site-packages/setuptools/_vendor/importlib_metadata/__pycache__/__init__.cpython-39.pyc ADDED
Binary file (39.9 kB). View file
 
.venv/Lib/site-packages/setuptools/_vendor/importlib_metadata/__pycache__/_adapters.cpython-39.pyc ADDED
Binary file (2.89 kB). View file
 
.venv/Lib/site-packages/setuptools/_vendor/importlib_metadata/__pycache__/_collections.cpython-39.pyc ADDED
Binary file (1.58 kB). View file
 
.venv/Lib/site-packages/setuptools/_vendor/importlib_metadata/__pycache__/_compat.cpython-39.pyc ADDED
Binary file (1.91 kB). View file
 
.venv/Lib/site-packages/setuptools/_vendor/importlib_metadata/__pycache__/_functools.cpython-39.pyc ADDED
Binary file (3.17 kB). View file
 
.venv/Lib/site-packages/setuptools/_vendor/importlib_metadata/__pycache__/_itertools.cpython-39.pyc ADDED
Binary file (2.05 kB). View file
 
.venv/Lib/site-packages/setuptools/_vendor/importlib_metadata/__pycache__/_meta.cpython-39.pyc ADDED
Binary file (3.27 kB). View file
 
.venv/Lib/site-packages/setuptools/_vendor/importlib_metadata/__pycache__/_text.cpython-39.pyc ADDED
Binary file (3.11 kB). View file
 
.venv/Lib/site-packages/setuptools/_vendor/importlib_metadata/_collections.py ADDED
@@ -0,0 +1,30 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import collections
2
+
3
+
4
+ # from jaraco.collections 3.3
5
+ class FreezableDefaultDict(collections.defaultdict):
6
+ """
7
+ Often it is desirable to prevent the mutation of
8
+ a default dict after its initial construction, such
9
+ as to prevent mutation during iteration.
10
+
11
+ >>> dd = FreezableDefaultDict(list)
12
+ >>> dd[0].append('1')
13
+ >>> dd.freeze()
14
+ >>> dd[1]
15
+ []
16
+ >>> len(dd)
17
+ 1
18
+ """
19
+
20
+ def __missing__(self, key):
21
+ return getattr(self, '_frozen', super().__missing__)(key)
22
+
23
+ def freeze(self):
24
+ self._frozen = lambda key: self.default_factory()
25
+
26
+
27
+ class Pair(collections.namedtuple('Pair', 'name value')):
28
+ @classmethod
29
+ def parse(cls, text):
30
+ return cls(*map(str.strip, text.split("=", 1)))
.venv/Lib/site-packages/setuptools/_vendor/importlib_metadata/_compat.py ADDED
@@ -0,0 +1,57 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import sys
2
+ import platform
3
+
4
+
5
+ __all__ = ['install', 'NullFinder']
6
+
7
+
8
+ def install(cls):
9
+ """
10
+ Class decorator for installation on sys.meta_path.
11
+
12
+ Adds the backport DistributionFinder to sys.meta_path and
13
+ attempts to disable the finder functionality of the stdlib
14
+ DistributionFinder.
15
+ """
16
+ sys.meta_path.append(cls())
17
+ disable_stdlib_finder()
18
+ return cls
19
+
20
+
21
+ def disable_stdlib_finder():
22
+ """
23
+ Give the backport primacy for discovering path-based distributions
24
+ by monkey-patching the stdlib O_O.
25
+
26
+ See #91 for more background for rationale on this sketchy
27
+ behavior.
28
+ """
29
+
30
+ def matches(finder):
31
+ return getattr(
32
+ finder, '__module__', None
33
+ ) == '_frozen_importlib_external' and hasattr(finder, 'find_distributions')
34
+
35
+ for finder in filter(matches, sys.meta_path): # pragma: nocover
36
+ del finder.find_distributions
37
+
38
+
39
+ class NullFinder:
40
+ """
41
+ A "Finder" (aka "MetaPathFinder") that never finds any modules,
42
+ but may find distributions.
43
+ """
44
+
45
+ @staticmethod
46
+ def find_spec(*args, **kwargs):
47
+ return None
48
+
49
+
50
+ def pypy_partial(val):
51
+ """
52
+ Adjust for variable stacklevel on partial under PyPy.
53
+
54
+ Workaround for #327.
55
+ """
56
+ is_pypy = platform.python_implementation() == 'PyPy'
57
+ return val + is_pypy
.venv/Lib/site-packages/setuptools/_vendor/importlib_metadata/_functools.py ADDED
@@ -0,0 +1,104 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import types
2
+ import functools
3
+
4
+
5
+ # from jaraco.functools 3.3
6
+ def method_cache(method, cache_wrapper=None):
7
+ """
8
+ Wrap lru_cache to support storing the cache data in the object instances.
9
+
10
+ Abstracts the common paradigm where the method explicitly saves an
11
+ underscore-prefixed protected property on first call and returns that
12
+ subsequently.
13
+
14
+ >>> class MyClass:
15
+ ... calls = 0
16
+ ...
17
+ ... @method_cache
18
+ ... def method(self, value):
19
+ ... self.calls += 1
20
+ ... return value
21
+
22
+ >>> a = MyClass()
23
+ >>> a.method(3)
24
+ 3
25
+ >>> for x in range(75):
26
+ ... res = a.method(x)
27
+ >>> a.calls
28
+ 75
29
+
30
+ Note that the apparent behavior will be exactly like that of lru_cache
31
+ except that the cache is stored on each instance, so values in one
32
+ instance will not flush values from another, and when an instance is
33
+ deleted, so are the cached values for that instance.
34
+
35
+ >>> b = MyClass()
36
+ >>> for x in range(35):
37
+ ... res = b.method(x)
38
+ >>> b.calls
39
+ 35
40
+ >>> a.method(0)
41
+ 0
42
+ >>> a.calls
43
+ 75
44
+
45
+ Note that if method had been decorated with ``functools.lru_cache()``,
46
+ a.calls would have been 76 (due to the cached value of 0 having been
47
+ flushed by the 'b' instance).
48
+
49
+ Clear the cache with ``.cache_clear()``
50
+
51
+ >>> a.method.cache_clear()
52
+
53
+ Same for a method that hasn't yet been called.
54
+
55
+ >>> c = MyClass()
56
+ >>> c.method.cache_clear()
57
+
58
+ Another cache wrapper may be supplied:
59
+
60
+ >>> cache = functools.lru_cache(maxsize=2)
61
+ >>> MyClass.method2 = method_cache(lambda self: 3, cache_wrapper=cache)
62
+ >>> a = MyClass()
63
+ >>> a.method2()
64
+ 3
65
+
66
+ Caution - do not subsequently wrap the method with another decorator, such
67
+ as ``@property``, which changes the semantics of the function.
68
+
69
+ See also
70
+ http://code.activestate.com/recipes/577452-a-memoize-decorator-for-instance-methods/
71
+ for another implementation and additional justification.
72
+ """
73
+ cache_wrapper = cache_wrapper or functools.lru_cache()
74
+
75
+ def wrapper(self, *args, **kwargs):
76
+ # it's the first call, replace the method with a cached, bound method
77
+ bound_method = types.MethodType(method, self)
78
+ cached_method = cache_wrapper(bound_method)
79
+ setattr(self, method.__name__, cached_method)
80
+ return cached_method(*args, **kwargs)
81
+
82
+ # Support cache clear even before cache has been created.
83
+ wrapper.cache_clear = lambda: None
84
+
85
+ return wrapper
86
+
87
+
88
+ # From jaraco.functools 3.3
89
+ def pass_none(func):
90
+ """
91
+ Wrap func so it's not called if its first param is None
92
+
93
+ >>> print_text = pass_none(print)
94
+ >>> print_text('text')
95
+ text
96
+ >>> print_text(None)
97
+ """
98
+
99
+ @functools.wraps(func)
100
+ def wrapper(param, *args, **kwargs):
101
+ if param is not None:
102
+ return func(param, *args, **kwargs)
103
+
104
+ return wrapper
.venv/Lib/site-packages/setuptools/_vendor/importlib_metadata/_itertools.py ADDED
@@ -0,0 +1,73 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ from itertools import filterfalse
2
+
3
+
4
+ def unique_everseen(iterable, key=None):
5
+ "List unique elements, preserving order. Remember all elements ever seen."
6
+ # unique_everseen('AAAABBBCCDAABBB') --> A B C D
7
+ # unique_everseen('ABBCcAD', str.lower) --> A B C D
8
+ seen = set()
9
+ seen_add = seen.add
10
+ if key is None:
11
+ for element in filterfalse(seen.__contains__, iterable):
12
+ seen_add(element)
13
+ yield element
14
+ else:
15
+ for element in iterable:
16
+ k = key(element)
17
+ if k not in seen:
18
+ seen_add(k)
19
+ yield element
20
+
21
+
22
+ # copied from more_itertools 8.8
23
+ def always_iterable(obj, base_type=(str, bytes)):
24
+ """If *obj* is iterable, return an iterator over its items::
25
+
26
+ >>> obj = (1, 2, 3)
27
+ >>> list(always_iterable(obj))
28
+ [1, 2, 3]
29
+
30
+ If *obj* is not iterable, return a one-item iterable containing *obj*::
31
+
32
+ >>> obj = 1
33
+ >>> list(always_iterable(obj))
34
+ [1]
35
+
36
+ If *obj* is ``None``, return an empty iterable:
37
+
38
+ >>> obj = None
39
+ >>> list(always_iterable(None))
40
+ []
41
+
42
+ By default, binary and text strings are not considered iterable::
43
+
44
+ >>> obj = 'foo'
45
+ >>> list(always_iterable(obj))
46
+ ['foo']
47
+
48
+ If *base_type* is set, objects for which ``isinstance(obj, base_type)``
49
+ returns ``True`` won't be considered iterable.
50
+
51
+ >>> obj = {'a': 1}
52
+ >>> list(always_iterable(obj)) # Iterate over the dict's keys
53
+ ['a']
54
+ >>> list(always_iterable(obj, base_type=dict)) # Treat dicts as a unit
55
+ [{'a': 1}]
56
+
57
+ Set *base_type* to ``None`` to avoid any special handling and treat objects
58
+ Python considers iterable as iterable:
59
+
60
+ >>> obj = 'foo'
61
+ >>> list(always_iterable(obj, base_type=None))
62
+ ['f', 'o', 'o']
63
+ """
64
+ if obj is None:
65
+ return iter(())
66
+
67
+ if (base_type is not None) and isinstance(obj, base_type):
68
+ return iter((obj,))
69
+
70
+ try:
71
+ return iter(obj)
72
+ except TypeError:
73
+ return iter((obj,))
.venv/Lib/site-packages/setuptools/_vendor/importlib_metadata/_meta.py ADDED
@@ -0,0 +1,67 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ from __future__ import annotations
2
+
3
+ import os
4
+ from typing import Protocol
5
+ from typing import Any, Dict, Iterator, List, Optional, TypeVar, Union, overload
6
+
7
+
8
+ _T = TypeVar("_T")
9
+
10
+
11
+ class PackageMetadata(Protocol):
12
+ def __len__(self) -> int: ... # pragma: no cover
13
+
14
+ def __contains__(self, item: str) -> bool: ... # pragma: no cover
15
+
16
+ def __getitem__(self, key: str) -> str: ... # pragma: no cover
17
+
18
+ def __iter__(self) -> Iterator[str]: ... # pragma: no cover
19
+
20
+ @overload
21
+ def get(
22
+ self, name: str, failobj: None = None
23
+ ) -> Optional[str]: ... # pragma: no cover
24
+
25
+ @overload
26
+ def get(self, name: str, failobj: _T) -> Union[str, _T]: ... # pragma: no cover
27
+
28
+ # overload per python/importlib_metadata#435
29
+ @overload
30
+ def get_all(
31
+ self, name: str, failobj: None = None
32
+ ) -> Optional[List[Any]]: ... # pragma: no cover
33
+
34
+ @overload
35
+ def get_all(self, name: str, failobj: _T) -> Union[List[Any], _T]:
36
+ """
37
+ Return all values associated with a possibly multi-valued key.
38
+ """
39
+
40
+ @property
41
+ def json(self) -> Dict[str, Union[str, List[str]]]:
42
+ """
43
+ A JSON-compatible form of the metadata.
44
+ """
45
+
46
+
47
+ class SimplePath(Protocol):
48
+ """
49
+ A minimal subset of pathlib.Path required by Distribution.
50
+ """
51
+
52
+ def joinpath(
53
+ self, other: Union[str, os.PathLike[str]]
54
+ ) -> SimplePath: ... # pragma: no cover
55
+
56
+ def __truediv__(
57
+ self, other: Union[str, os.PathLike[str]]
58
+ ) -> SimplePath: ... # pragma: no cover
59
+
60
+ @property
61
+ def parent(self) -> SimplePath: ... # pragma: no cover
62
+
63
+ def read_text(self, encoding=None) -> str: ... # pragma: no cover
64
+
65
+ def read_bytes(self) -> bytes: ... # pragma: no cover
66
+
67
+ def exists(self) -> bool: ... # pragma: no cover
.venv/Lib/site-packages/setuptools/_vendor/importlib_metadata/_text.py ADDED
@@ -0,0 +1,99 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import re
2
+
3
+ from ._functools import method_cache
4
+
5
+
6
+ # from jaraco.text 3.5
7
+ class FoldedCase(str):
8
+ """
9
+ A case insensitive string class; behaves just like str
10
+ except compares equal when the only variation is case.
11
+
12
+ >>> s = FoldedCase('hello world')
13
+
14
+ >>> s == 'Hello World'
15
+ True
16
+
17
+ >>> 'Hello World' == s
18
+ True
19
+
20
+ >>> s != 'Hello World'
21
+ False
22
+
23
+ >>> s.index('O')
24
+ 4
25
+
26
+ >>> s.split('O')
27
+ ['hell', ' w', 'rld']
28
+
29
+ >>> sorted(map(FoldedCase, ['GAMMA', 'alpha', 'Beta']))
30
+ ['alpha', 'Beta', 'GAMMA']
31
+
32
+ Sequence membership is straightforward.
33
+
34
+ >>> "Hello World" in [s]
35
+ True
36
+ >>> s in ["Hello World"]
37
+ True
38
+
39
+ You may test for set inclusion, but candidate and elements
40
+ must both be folded.
41
+
42
+ >>> FoldedCase("Hello World") in {s}
43
+ True
44
+ >>> s in {FoldedCase("Hello World")}
45
+ True
46
+
47
+ String inclusion works as long as the FoldedCase object
48
+ is on the right.
49
+
50
+ >>> "hello" in FoldedCase("Hello World")
51
+ True
52
+
53
+ But not if the FoldedCase object is on the left:
54
+
55
+ >>> FoldedCase('hello') in 'Hello World'
56
+ False
57
+
58
+ In that case, use in_:
59
+
60
+ >>> FoldedCase('hello').in_('Hello World')
61
+ True
62
+
63
+ >>> FoldedCase('hello') > FoldedCase('Hello')
64
+ False
65
+ """
66
+
67
+ def __lt__(self, other):
68
+ return self.lower() < other.lower()
69
+
70
+ def __gt__(self, other):
71
+ return self.lower() > other.lower()
72
+
73
+ def __eq__(self, other):
74
+ return self.lower() == other.lower()
75
+
76
+ def __ne__(self, other):
77
+ return self.lower() != other.lower()
78
+
79
+ def __hash__(self):
80
+ return hash(self.lower())
81
+
82
+ def __contains__(self, other):
83
+ return super().lower().__contains__(other.lower())
84
+
85
+ def in_(self, other):
86
+ "Does self appear in other?"
87
+ return self in FoldedCase(other)
88
+
89
+ # cache lower since it's likely to be called frequently.
90
+ @method_cache
91
+ def lower(self):
92
+ return super().lower()
93
+
94
+ def index(self, sub):
95
+ return self.lower().index(sub.lower())
96
+
97
+ def split(self, splitter=' ', maxsplit=0):
98
+ pattern = re.compile(re.escape(splitter), re.I)
99
+ return pattern.split(self, maxsplit)
.venv/Lib/site-packages/setuptools/_vendor/importlib_metadata/compat/__init__.py ADDED
File without changes
.venv/Lib/site-packages/setuptools/_vendor/importlib_metadata/compat/__pycache__/__init__.cpython-39.pyc ADDED
Binary file (216 Bytes). View file
 
.venv/Lib/site-packages/setuptools/_vendor/importlib_metadata/compat/__pycache__/py311.cpython-39.pyc ADDED
Binary file (1.05 kB). View file
 
.venv/Lib/site-packages/setuptools/_vendor/importlib_metadata/compat/__pycache__/py39.cpython-39.pyc ADDED
Binary file (1.22 kB). View file
 
.venv/Lib/site-packages/setuptools/_vendor/importlib_metadata/compat/py311.py ADDED
@@ -0,0 +1,22 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import os
2
+ import pathlib
3
+ import sys
4
+ import types
5
+
6
+
7
+ def wrap(path): # pragma: no cover
8
+ """
9
+ Workaround for https://github.com/python/cpython/issues/84538
10
+ to add backward compatibility for walk_up=True.
11
+ An example affected package is dask-labextension, which uses
12
+ jupyter-packaging to install JupyterLab javascript files outside
13
+ of site-packages.
14
+ """
15
+
16
+ def relative_to(root, *, walk_up=False):
17
+ return pathlib.Path(os.path.relpath(path, root))
18
+
19
+ return types.SimpleNamespace(relative_to=relative_to)
20
+
21
+
22
+ relative_fix = wrap if sys.version_info < (3, 12) else lambda x: x
.venv/Lib/site-packages/setuptools/_vendor/importlib_metadata/compat/py39.py ADDED
@@ -0,0 +1,36 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ """
2
+ Compatibility layer with Python 3.8/3.9
3
+ """
4
+
5
+ from typing import TYPE_CHECKING, Any, Optional
6
+
7
+ if TYPE_CHECKING: # pragma: no cover
8
+ # Prevent circular imports on runtime.
9
+ from .. import Distribution, EntryPoint
10
+ else:
11
+ Distribution = EntryPoint = Any
12
+
13
+
14
+ def normalized_name(dist: Distribution) -> Optional[str]:
15
+ """
16
+ Honor name normalization for distributions that don't provide ``_normalized_name``.
17
+ """
18
+ try:
19
+ return dist._normalized_name
20
+ except AttributeError:
21
+ from .. import Prepared # -> delay to prevent circular imports.
22
+
23
+ return Prepared.normalize(getattr(dist, "name", None) or dist.metadata['Name'])
24
+
25
+
26
+ def ep_matches(ep: EntryPoint, **params) -> bool:
27
+ """
28
+ Workaround for ``EntryPoint`` objects without the ``matches`` method.
29
+ """
30
+ try:
31
+ return ep.matches(**params)
32
+ except AttributeError:
33
+ from .. import EntryPoint # -> delay to prevent circular imports.
34
+
35
+ # Reconstruct the EntryPoint object to make sure it is compatible.
36
+ return EntryPoint(ep.name, ep.value, ep.group).matches(**params)
.venv/Lib/site-packages/setuptools/_vendor/inflect/__init__.py ADDED
The diff for this file is too large to render. See raw diff
 
.venv/Lib/site-packages/setuptools/_vendor/inflect/py.typed ADDED
File without changes
.venv/Lib/site-packages/setuptools/_vendor/jaraco.functools-4.0.1.dist-info/RECORD ADDED
@@ -0,0 +1,10 @@
 
 
 
 
 
 
 
 
 
 
 
1
+ jaraco.functools-4.0.1.dist-info/INSTALLER,sha256=zuuue4knoyJ-UwPPXg8fezS7VCrXJQrAP7zeNuwvFQg,4
2
+ jaraco.functools-4.0.1.dist-info/LICENSE,sha256=htoPAa6uRjSKPD1GUZXcHOzN55956HdppkuNoEsqR0E,1023
3
+ jaraco.functools-4.0.1.dist-info/METADATA,sha256=i4aUaQDX-jjdEQK5wevhegyx8JyLfin2HyvaSk3FHso,2891
4
+ jaraco.functools-4.0.1.dist-info/RECORD,,
5
+ jaraco.functools-4.0.1.dist-info/WHEEL,sha256=GJ7t_kWBFywbagK5eo9IoUwLW6oyOeTKmQ-9iHFVNxQ,92
6
+ jaraco.functools-4.0.1.dist-info/top_level.txt,sha256=0JnN3LfXH4LIRfXL-QFOGCJzQWZO3ELx4R1d_louoQM,7
7
+ jaraco/functools/__init__.py,sha256=hEAJaS2uSZRuF_JY4CxCHIYh79ZpxaPp9OiHyr9EJ1w,16642
8
+ jaraco/functools/__init__.pyi,sha256=gk3dsgHzo5F_U74HzAvpNivFAPCkPJ1b2-yCd62dfnw,3878
9
+ jaraco/functools/__pycache__/__init__.cpython-312.pyc,,
10
+ jaraco/functools/py.typed,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
.venv/Lib/site-packages/setuptools/_vendor/jaraco.functools-4.0.1.dist-info/WHEEL ADDED
@@ -0,0 +1,5 @@
 
 
 
 
 
 
1
+ Wheel-Version: 1.0
2
+ Generator: bdist_wheel (0.43.0)
3
+ Root-Is-Purelib: true
4
+ Tag: py3-none-any
5
+
.venv/Lib/site-packages/setuptools/_vendor/jaraco.functools-4.0.1.dist-info/top_level.txt ADDED
@@ -0,0 +1 @@
 
 
1
+ jaraco
.venv/Lib/site-packages/setuptools/_vendor/jaraco.text-3.12.1.dist-info/INSTALLER ADDED
@@ -0,0 +1 @@
 
 
1
+ pip
.venv/Lib/site-packages/setuptools/_vendor/jaraco.text-3.12.1.dist-info/LICENSE ADDED
@@ -0,0 +1,17 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ Permission is hereby granted, free of charge, to any person obtaining a copy
2
+ of this software and associated documentation files (the "Software"), to
3
+ deal in the Software without restriction, including without limitation the
4
+ rights to use, copy, modify, merge, publish, distribute, sublicense, and/or
5
+ sell copies of the Software, and to permit persons to whom the Software is
6
+ furnished to do so, subject to the following conditions:
7
+
8
+ The above copyright notice and this permission notice shall be included in
9
+ all copies or substantial portions of the Software.
10
+
11
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
12
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
13
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
14
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
15
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
16
+ FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS
17
+ IN THE SOFTWARE.