Project

General

Profile

Actions

Bug #18480

closed

Arv-put tries to open non-regular files

Added by Lucas Di Pentima over 2 years ago. Updated over 2 years ago.

Status:
Resolved
Priority:
Normal
Assigned To:
Category:
SDKs
Target version:
Story points:
-
Release relationship:
Auto

Description

A customer reported an issue when trying to use arv-put on paths that include special files (like named pipes), and already provided a patch for it:

--- a/sdk/python/arvados/commands/put.py
+++ b/sdk/python/arvados/commands/put.py
@@ -576,6 +576,9 @@
                     files.sort()
                     for f in files:
                         filepath = os.path.join(root, f)
+                        if not os.path.isfile(filepath):
+                            self.logger.warning("Skipping non-regular file '{}'".format(filepath))
+                            continue
                         # Add its size to the total bytes count (if applicable)
                         if self.follow_links or (not os.path.islink(filepath)):
                             if self.bytes_expected is not None:

Subtasks 1 (0 open1 closed)

Task #18483: Review 18480-arvput-special-files-handlingResolvedLucas Di Pentima11/26/2021Actions
Actions

Also available in: Atom PDF