Commit 59e0ca3
committed
Defer loading of importtlib.metadata
This package is needed for `load_setuptools_entrypoints`, but it is
quite slow to import. While most users do use
`load_setuptools_entrypoints`, maybe some don't, so let's let them avoid
the cost.
For `import pluggy`:
Before: 36ms
After: 11ms1 parent e474438 commit 59e0ca3
1 file changed
+7
-1
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | 2 | | |
3 | | - | |
4 | 3 | | |
5 | 4 | | |
6 | 5 | | |
| |||
11 | 10 | | |
12 | 11 | | |
13 | 12 | | |
| 13 | + | |
14 | 14 | | |
15 | 15 | | |
16 | 16 | | |
| |||
26 | 26 | | |
27 | 27 | | |
28 | 28 | | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
29 | 33 | | |
30 | 34 | | |
31 | 35 | | |
| |||
384 | 388 | | |
385 | 389 | | |
386 | 390 | | |
| 391 | + | |
| 392 | + | |
387 | 393 | | |
388 | 394 | | |
389 | 395 | | |
| |||
0 commit comments