Skip to content

Commit

Permalink
Add comment to protect the deferred import.
Browse files Browse the repository at this point in the history
  • Loading branch information
jaraco committed Sep 11, 2024
1 parent 18eb2da commit 3f78dc1
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions importlib_metadata/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -672,6 +672,7 @@ def origin(self):
return self._load_json('direct_url.json')

def _load_json(self, filename):
# Deferred for performance (python/importlib_metadata#503)
import json

return pass_none(json.loads)(
Expand Down

0 comments on commit 3f78dc1

Please sign in to comment.