diff options
author | Brett Cannon <brettcannon@users.noreply.github.com> | 2018-04-30 11:31:45 -0700 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-04-30 11:31:45 -0700 |
commit | 3ab9365dca8438f89b2060cd3eebe00606133dc4 (patch) | |
tree | 7844d510039f747edd6ed5cb2b1e60977c20a30a /Lib/importlib/abc.py | |
parent | 10f715d71218ece737f990fa55027b8e1120cc3a (diff) | |
download | cpython-git-3ab9365dca8438f89b2060cd3eebe00606133dc4.tar.gz |
bpo-33254: do not return an empty list when asking for the contents of a namespace package (GH-6467)
Diffstat (limited to 'Lib/importlib/abc.py')
-rw-r--r-- | Lib/importlib/abc.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/Lib/importlib/abc.py b/Lib/importlib/abc.py index d2f45093a4..dbdd5bf641 100644 --- a/Lib/importlib/abc.py +++ b/Lib/importlib/abc.py @@ -381,8 +381,8 @@ class ResourceReader(metaclass=abc.ABCMeta): @abc.abstractmethod def contents(self): - """Return an iterator of strings over the contents of the package.""" - return iter([]) + """Return an iterable of strings over the contents of the package.""" + return [] _register(ResourceReader, machinery.SourceFileLoader) |