Skip to content

Commit 30fbe5c

Browse files
author
Peter Amstutz
committed
Don't call fsaccess.size() if we already have a size.
1 parent b82ce7a commit 30fbe5c

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

cwltool/process.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -363,7 +363,8 @@ def cleanIntermediate(output_dirs): # type: (Iterable[Text]) -> None
363363
def add_sizes(fsaccess, obj): # type: (StdFsAccess, Dict[Text, Any]) -> None
364364
if 'location' in obj:
365365
try:
366-
obj["size"] = fsaccess.size(obj["location"])
366+
if "size" not in obj:
367+
obj["size"] = fsaccess.size(obj["location"])
367368
except OSError:
368369
pass
369370
elif 'contents' in obj:

0 commit comments

Comments
 (0)