1 |
Stop returning directories from FlatLayout.get_filenames(). This causes |
2 |
emirrordist to wrongly presume directories created by new layout |
3 |
to be distfiles, and causes some noisy errors. |
4 |
|
5 |
Signed-off-by: Michał Górny <mgorny@g.o> |
6 |
--- |
7 |
lib/portage/package/ebuild/fetch.py | 5 ++++- |
8 |
1 file changed, 4 insertions(+), 1 deletion(-) |
9 |
|
10 |
diff --git a/lib/portage/package/ebuild/fetch.py b/lib/portage/package/ebuild/fetch.py |
11 |
index 5d0bc7355..cd204b755 100644 |
12 |
--- a/lib/portage/package/ebuild/fetch.py |
13 |
+++ b/lib/portage/package/ebuild/fetch.py |
14 |
@@ -35,6 +35,7 @@ portage.proxy.lazyimport.lazyimport(globals(), |
15 |
'portage.util:atomic_ofstream', |
16 |
'portage.util.configparser:SafeConfigParser,read_configs,' + |
17 |
'ConfigParserError', |
18 |
+ 'portage.util.install_mask:_raise_exc', |
19 |
'portage.util._urlopen:urlopen', |
20 |
) |
21 |
|
22 |
@@ -269,7 +270,9 @@ class FlatLayout(object): |
23 |
return filename |
24 |
|
25 |
def get_filenames(self, distdir): |
26 |
- return iter(os.listdir(distdir)) |
27 |
+ for dirpath, dirnames, filenames in os.walk(distdir, |
28 |
+ onerror=_raise_exc): |
29 |
+ return iter(filenames) |
30 |
|
31 |
@staticmethod |
32 |
def verify_args(args): |
33 |
-- |
34 |
2.23.0 |