summaryrefslogtreecommitdiffstats
path: root/Lib/importlib/metadata/__init__.py
Commit message (Collapse)AuthorAgeFilesLines
* gh-120910: Fix issue resolving relative paths outside site-packages. (#120911)Jason R. Coombs2024-06-231-1/+1
| | | Incorporates changes from importlib_metadata 7.2.1.
* GH-109653: Defer import of ``importlib.metadata._adapters`` (#109829)Adam Turner2024-03-211-1/+4
| | | | | | | | | | | * adapters * Add comments for deferred imports with links to rationale. * Add blurb --------- Co-authored-by: Jason R. Coombs <jaraco@jaraco.com>
* gh-117089: Apply changes from importlib_metadata 7.1.0 (#117094)Jason R. Coombs2024-03-211-32/+123
| | | | | * Apply changes from importlib_metadata 7.1.0 * Include the data sources in the makefile (even though they're not needed)
* gh-116811: Ensure MetadataPathFinder.invalidate_caches is reachable when ↵Jason R. Coombs2024-03-141-0/+1
| | | | | | | | | delegated through PathFinder. (#116812) * Make MetadataPathFinder a proper classmethod. * In PathFinder.invalidate_caches, also invoke MetadataPathFinder.invalidate_caches. * Add blurb
* gh-109653: Improve import time of importlib.metadata / email.utils (#114664)Shantanu2024-01-291-1/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | My criterion for delayed imports is that they're only worth it if the majority of users of the module would benefit from it, otherwise you're just moving latency around unpredictably. mktime_tz is not used anywhere in the standard library and grep.app indicates it's not got much use in the ecosystem either. Distribution.files is not nearly as widely used as other importlib.metadata APIs, so we defer the csv import. Before: ``` λ hyperfine -w 8 './python -c "import importlib.metadata"' Benchmark 1: ./python -c "import importlib.metadata" Time (mean ± σ): 65.1 ms ± 0.5 ms [User: 55.3 ms, System: 9.8 ms] Range (min … max): 64.4 ms … 66.4 ms 44 runs ``` After: ``` λ hyperfine -w 8 './python -c "import importlib.metadata"' Benchmark 1: ./python -c "import importlib.metadata" Time (mean ± σ): 62.0 ms ± 0.3 ms [User: 52.5 ms, System: 9.6 ms] Range (min … max): 61.3 ms … 62.8 ms 46 runs ``` for about a 3ms saving with warm disk cache, maybe 7-11ms with cold disk cache.
* gh-113174: Sync with importlib_metadata 7.0 (#113175)Jason R. Coombs2023-12-211-76/+107
| | | | | | | | | | | | | | | | | | | | | | | * Sync with importlib_metadata 7.0.0 * Add blurb * Update docs to reflect changes. * Link datamodel docs for object.__getitem__ Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com> * Add what's new for removed __getattr__ * Link datamodel docs for object.__getitem__ Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com> * Add exclamation point, as that seems to be used for other classes. --------- Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
* gh-105407: Remove unused imports in the stdlib (#105411)Victor Stinner2023-06-061-1/+0
|
* gh-103661: Apply bugfix from importlib_metadata 6.5.1 and restore test. ↵Jason R. Coombs2023-04-221-12/+14
| | | | (#103681)
* Sync with importlib_metadata 6.5 (GH-103584)Jason R. Coombs2023-04-211-14/+84
|
* gh-97781: Apply changes from importlib_metadata 5. (GH-97785)Jason R. Coombs2022-10-061-201/+10
| | | | | | | * gh-97781: Apply changes from importlib_metadata 5. * Apply changes from upstream * Apply changes from upstream.
* gh-93259: Validate arg to ``Distribution.from_name``. (GH-94270)Jason R. Coombs2022-06-261-14/+34
| | | Syncs with importlib_metadata 4.12.0.
* bpo-47004: Sync with importlib_metadata 4.11.3. (#31854)Jason R. Coombs2022-03-131-18/+39
|
* bpo-46246: add missing __slots__ to importlib.metadata.DeprecatedList (GH-30452)Arie Bovenberg2022-02-111-0/+2
| | | | | | | Confirmed with @jaraco that this indeed needs a fix. A question that came up while I was digging into the code: I think `SelectableGroups` could similarly use `__slots__ = ()`, since its purpose seems only for convenience around `dict`, not to have attributes of its own. Automerge-Triggered-By: GH:jaraco
* bpo-46474: Avoid REDoS in EntryPoint.pattern (sync with importlib_metadata ↵Jason R. Coombs2022-01-231-2/+2
| | | | 4.10.1) (GH-30803)
* bpo-46474: Apply changes from importlib_metadata 4.10.0 (GH-30802)Jason R. Coombs2022-01-231-12/+0
|
* bpo-44893: Implement EntryPoint as simple class with attributes. (GH-30150)Jason R. Coombs2021-12-161-63/+100
| | | | | * bpo-44893: Implement EntryPoint as simple class and deprecate tuple access in favor of attribute access. Syncs with importlib_metadata 4.8.1. * Apply refactorings found in importlib_metadata 4.8.2.
* bpo-46105: Honor spec when generating requirement specs with urls and ↵Jason R. Coombs2021-12-161-2/+11
| | | | extras. (GH-30151)
* [bpo-45765] Fix distribution discovery on empty path. (#29487)Jason R. Coombs2021-11-091-1/+1
|
* bpo-44464: Remove special exclusion for flake8 in the deprecation warnings. ↵Jason R. Coombs2021-06-271-9/+1
| | | | | (#26807) Sync with importlib_metadata 4.6.
* bpo-44246: Restore compatibility in entry_points (GH-26468)Jason R. Coombs2021-05-311-1/+102
| | | | | | | * bpo-44246: Entry points performance improvements. From importlib_metadata 4.3.1. * bpo-44246: Sync with importlib_metadata 4.4
* bpo-44246: Entry points performance improvements. (GH-26467)Jason R. Coombs2021-05-311-1/+23
| | | From importlib_metadata 4.3.1.
* bpo-38693: importlib.metadata f-strings (GH-26383)Jason R. Coombs2021-05-261-5/+4
| | | Automerge-Triggered-By: GH:jaraco
* bpo-44241: Incorporate changes from importlib_metadata 4.1. (#26382)Jason R. Coombs2021-05-261-8/+9
|
* bpo-44210: make importlib.metadata._meta.PackageMetadata public (GH-26299)Filipe Laíns2021-05-231-0/+2
| | | | | Signed-off-by: Filipe Laíns <lains@riseup.net> Automerge-Triggered-By: GH:jaraco
* bpo-43926: Cleaner metadata with PEP 566 JSON support. (GH-25565)Jason R. Coombs2021-05-021-0/+890
| | | | | | | | | * bpo-43926: Cleaner metadata with PEP 566 JSON support. * Add blurb * Add versionchanged and versionadded declarations for changes to metadata. * Use descriptor for PEP 566
* Make importlib.metadata a simple module (#15153)Barry Warsaw2019-08-061-397/+0
|
* bpo-37697: Sync with importlib_metadata 0.19 (#14993)Jason R. Coombs2019-07-281-1/+1
| | | | | | | | * bpo-37697: Sync with importlib_metadata 0.19 * Run make regen-importlib * 📜🤖 Added by blurb_it.
* cross port importlib-metadata PR #76 (#13903)Anthony Sottile2019-06-071-0/+2
| | | https://gitlab.com/python-devs/importlib_metadata/merge_requests/76
* Don't crash if there exists an EGG-INFO directory on sys.path (#13667)Anthony Sottile2019-05-301-1/+2
| | | | | | | | * Don't crash if there exists an EGG-INFO directory on sys.path cross-port of https://gitlab.com/python-devs/importlib_metadata/merge_requests/72 * Also catch PermissionError for windows
* bpo-34632: Add importlib.metadata (GH-12547)Jason R. Coombs2019-05-241-0/+394
Add importlib.metadata module as forward port of the standalone importlib_metadata.