From 098a519305262ee07bba6c9bd8b73589797b9e40 Mon Sep 17 00:00:00 2001 From: Saugat Pachhai Date: Wed, 31 Mar 2021 05:46:49 -0700 Subject: [PATCH] webdav: use root url to check and on mkdir to find recurse depth (#5742) --- dvc/fs/webdav.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/dvc/fs/webdav.py b/dvc/fs/webdav.py index 9b66e635b..b8536ecce 100644 --- a/dvc/fs/webdav.py +++ b/dvc/fs/webdav.py @@ -117,7 +117,7 @@ class WebDAVFileSystem(BaseFileSystem): # pylint:disable=abstract-method ) # Check whether connection is valid (root should always exist) - if not client.check("/"): + if not client.check(self.path_info.path): raise WebDAVConnectionError(self.hostname) return client @@ -213,7 +213,7 @@ class WebDAVFileSystem(BaseFileSystem): # pylint:disable=abstract-method # Creates directories def makedirs(self, path_info): # Terminate recursion - if path_info.path == "/" or self.exists(path_info): + if path_info.path == self.path_info.path or self.exists(path_info): return # Recursively descent to root