From 05b5e9dc2911c1762bed7634150d4e84a9b90574 Mon Sep 17 00:00:00 2001 From: Jon Burdo Date: Thu, 6 Jan 2022 11:32:43 -0500 Subject: [PATCH] handle paths ending with sep in dvc.fs.path.Path.parts --- dvc/fs/path.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dvc/fs/path.py b/dvc/fs/path.py index b0c02db8c7..7545fb7a88 100644 --- a/dvc/fs/path.py +++ b/dvc/fs/path.py @@ -15,7 +15,7 @@ def join(self, *parts): return self.flavour.join(*parts) def parts(self, path): - drive, path = self.flavour.splitdrive(path) + drive, path = self.flavour.splitdrive(path.rstrip(self.flavour.sep)) ret = [] while True: