GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — gh-109653: Improve import time of importlib.metadata / email.utils (p… · python/importlib_metadata@b4ce0ff

File tree

Expand file treeCollapse file tree
Open diff view settings
Filter options
  • importlib_metadata
    • __init__.py
  • newsfragments
    • +.feature.rst
Expand file treeCollapse file tree
Open diff view settings
Collapse file

‎importlib_metadata/__init__.py‎

Copy file name to clipboardExpand all lines: importlib_metadata/__init__.py
+4-1Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,6 @@
33
import os
44
import re
55
import abc
6-
import csv
76
import sys
87
import json
98
import zipp
@@ -522,6 +521,10 @@ def make_file(name, hash=None, size_str=None):
522521

523522
@pass_none
524523
def make_files(lines):
524+
# Delay csv import, since Distribution.files is not as widely used
525+
# as other parts of importlib.metadata
526+
import csv
527+
525528
return starmap(make_file, csv.reader(lines))
526529

527530
@pass_none
Collapse file

‎newsfragments/+.feature.rst‎

Copy file name to clipboard
+1Lines changed: 1 addition & 0 deletions
  • Display the source diff
  • Display the rich diff
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
Improve import time (python/cpython#114664).

0 commit comments

Comments
0 (0)
You are visitor 01402503 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.