Merge branch 'master' into 10081-cwl-run-same-job
[arvados.git] / sdk / cwl / arvados_cwl / pathmapper.py
index 40a64ffd20b5a769421f297c8a29cf35cec1d8d3..ffdade0f5ecbc1562e67dfacdf090c77e7fa24c2 100644 (file)
@@ -52,7 +52,7 @@ class ArvPathMapper(PathMapper):
         elif srcobj["class"] == "Directory":
             if isinstance(src, basestring) and ArvPathMapper.pdh_dirpath.match(src):
                 self._pathmap[src] = MapperEnt(src, self.collection_pattern % src[5:], "Directory")
-            for l in srcobj["listing"]:
+            for l in srcobj.get("listing", []):
                 self.visit(l, uploadfiles)
 
     def addentry(self, obj, c, path, subdirs):