Skip to content

Migrate WebDAV file source to fsspec/webdav4#22477

Open
PlushZ wants to merge 1 commit intogalaxyproject:devfrom
PlushZ:migrate-webdav-to-fsspec
Open

Migrate WebDAV file source to fsspec/webdav4#22477
PlushZ wants to merge 1 commit intogalaxyproject:devfrom
PlushZ:migrate-webdav-to-fsspec

Conversation

@PlushZ
Copy link
Copy Markdown
Contributor

@PlushZ PlushZ commented Apr 14, 2026

Replace the WebDAV file source backend from fs.webdavfs to webdav4 via Galaxy’s FsspecFilesSource, keeping the existing user/admin config shape (url + root). The change normalizes those fields into an internal base_url, which fixes the current serialization bug where import/export jobs could lose the WebDAV endpoint after file source rehydration.
Migration sub-issue #21869

How to test the changes?

(Select all options that apply)

  • I've included appropriate automated tests.
  • This is a refactoring of components with existing test coverage.
  • Instructions for manual testing are as follows:
    1. [add testing steps and prerequisites here if you didn't write automated tests covering all your changes]

License

  • I agree to license these and all my past contributions to the core galaxy codebase under the MIT license.

Comment on lines +264 to +268
def check_fs_webdavfs(self):
return self.check_webdav4()

def check_webdavclient3(self):
# fs.webdavfs dependency for which we need an unreleased version
return self.check_fs_webdavfs()
return self.check_webdav4()
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think those are not needed anymore

Comment on lines +68 to +76
def normalize_endpoint(cls, data: Any) -> Any:
if not isinstance(data, dict):
return data
normalized = dict(data)
normalized["root"] = _normalize_root(normalized.get("root"))
normalized["base_url"] = _normalize_base_url(
normalized.get("base_url") or _compose_base_url(normalized.get("url"), normalized.get("root"))
)
return normalized
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The path normalization is a bit complex, and it's done at the template level, it probably should follow the same pattern as other file sources overriding _adapt_entry_path and/or _to_filesystem_path, etc.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

Status: Needs Review

Development

Successfully merging this pull request may close these issues.

2 participants