17800: Improves help message. Shows warnings when ignoring given paths.
authorLucas Di Pentima <lucas.dipentima@curii.com>
Mon, 14 Jun 2021 17:26:21 +0000 (14:26 -0300)
committerLucas Di Pentima <lucas.dipentima@curii.com>
Mon, 14 Jun 2021 17:27:21 +0000 (14:27 -0300)
Arvados-DCO-1.1-Signed-off-by: Lucas Di Pentima <lucas.dipentima@curii.com>

sdk/python/arvados/commands/put.py

index 813c6ef2978d4af6ce0a658496a7142314c48f5a..7f884b27e0969bbf8e2760a1a4e475499f3123eb 100644 (file)
@@ -173,7 +173,8 @@ Follow file and directory symlinks (default).
 """)
 _group.add_argument('--no-follow-links', action='store_false', dest='follow_links',
                     help="""
-Do not follow file and directory symlinks.
+Ignore file and directory symlinks. Even paths given explicitly on the
+command line will be skipped if they are symlinks.
 """)
 
 
@@ -525,6 +526,7 @@ class ArvPutUploadJob(object):
             elif not os.path.exists(path):
                  raise PathDoesNotExistError(u"file or directory '{}' does not exist.".format(path))
             elif (not self.follow_links) and os.path.islink(path):
+                self.logger.warning("Skipping symlink '{}'".format(path))
                 continue
             elif os.path.isdir(path):
                 # Use absolute paths on cache index so CWD doesn't interfere