subdir = subdir[:-1]
infos.append(FileInfo(subdir, True, None))
else: // Just a plain old blob
file_name = r.name[len(artifact_path)+1:]
infos.append(FileInfo(file_name, False, r.properties.content_length))
// Check whether a new marker is returned, meaning we have to make another request
if results.next_marker:
marker = results.next_marker
After Change
if isinstance(r, BlobPrefix): // This is a prefix for items in a subdirectory
// Separator needs to be fixed as "/" because of azure blob storage pattern.
// Do not change to os.relpath because in Windows system path separator is "\"
subdir = posixpath.relpath(path=r.name, start=artifact_path)
if subdir.endswith("/"):
subdir = subdir[:-1]
infos.append(FileInfo(subdir, True, None))
else: // Just a plain old blob