Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

The 'getinfo' method returns an extra root path #36

Open
y805939188 opened this issue Feb 21, 2024 · 1 comment
Open

The 'getinfo' method returns an extra root path #36

y805939188 opened this issue Feb 21, 2024 · 1 comment

Comments

@y805939188
Copy link

When I execute the function listdir() to get file list, if there is a path in url, the method will return an extra path name.
There is a test directory in my root path:
image
My code attempts to obtain a list of files in the test directory:

url = 'http://localhost:6666/test'
handle = WebDAVFS(url, login='admin', password='admin')
test = handle.listdir('./')
print(list(test))

I expected to only get 'c.txt' and 'd. txt', but now I will get an extra 'test':
image

@weijia
Copy link

weijia commented Nov 3, 2024

I met similar problem. Actually the code should be like:

url = 'http://localhost:6666'
handle = WebDAVFS(url, login='admin', password='admin', root='test')
test = handle.listdir('./')
print(list(test))

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants