remote-exec: Only copy command line arguments which name files that exist.

Speculative fix for failing buildbot:
https://lab.llvm.org/buildbot/#/builders/193/builds/8961
This commit is contained in:
Peter Collingbourne 2025-07-09 20:22:43 -07:00
parent 831b198c65
commit c4f18d6874

View File

@ -130,11 +130,12 @@ def main():
]
)
else:
# Copy only the files, which are specified in the command line.
# Copy them to remote host one by one.
# Copy only files which are specified in the command line and exist on
# the host. Copy them to the remote host one by one.
for x in commandLine:
_, f = os.path.split(x)
subprocess.check_call(scp(args, x, pathOnRemote(f)))
if os.path.exists(x):
_, f = os.path.split(x)
subprocess.check_call(scp(args, x, pathOnRemote(f)))
# Make sure all executables in the remote command line have 'execute'
# permissions on the remote host. The host that compiled the test-executable