summaryrefslogtreecommitdiffstats
path: root/contrib/tools/python3/Lib/zipimport.py
diff options
context:
space:
mode:
authorshadchin <[email protected]>2024-10-27 10:52:33 +0300
committershadchin <[email protected]>2024-10-27 11:03:47 +0300
commit1529383373617c6d14ad4972afdc46a5eb35f954 (patch)
tree229b7647fafadd4ee4b93d20e606c534ad697365 /contrib/tools/python3/Lib/zipimport.py
parent41d598c624442bf6918407466dac3316b8277347 (diff)
Update Python 3 to 3.12.7
commit_hash:052a122399d67f1ea5dfbc5f6457e3e06200becf
Diffstat (limited to 'contrib/tools/python3/Lib/zipimport.py')
-rw-r--r--contrib/tools/python3/Lib/zipimport.py12
1 files changed, 2 insertions, 10 deletions
diff --git a/contrib/tools/python3/Lib/zipimport.py b/contrib/tools/python3/Lib/zipimport.py
index a7333a4c490..7669abd6c47 100644
--- a/contrib/tools/python3/Lib/zipimport.py
+++ b/contrib/tools/python3/Lib/zipimport.py
@@ -254,17 +254,9 @@ class zipimporter(_bootstrap_external._LoaderBasics):
def get_resource_reader(self, fullname):
- """Return the ResourceReader for a package in a zip file.
-
- If 'fullname' is a package within the zip file, return the
- 'ResourceReader' object for the package. Otherwise return None.
- """
- try:
- if not self.is_package(fullname):
- return None
- except ZipImportError:
- return None
+ """Return the ResourceReader for a module in a zip file."""
from importlib.readers import ZipReader
+
return ZipReader(self, fullname)