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

Support windows-style path...? #240

Open
YooSunYoung opened this issue Sep 16, 2024 · 2 comments
Open

Support windows-style path...? #240

YooSunYoung opened this issue Sep 16, 2024 · 2 comments

Comments

@YooSunYoung
Copy link
Member

We're not handling str path and just pass it to h5py.File here

else:
self._file = h5py.File(name, *args, **kwargs)
self._manage_file_context = True
super().__init__(self._file, definitions=definitions)

But maybe we can wrap it with pathlib.Path to make sure it works...?

Since you copy + paste from windows finder, it gives you path with \
but users might not know of pathlib.Path, especially when you're using high-level interface like workflows.

@jl-wynen
Copy link
Member

I tried it in a Windows VM and it seems to work with backslashes. But you have to remember to use a raw string. Otherwise, backslashes are interpreted as escape sequences. (This is not very nice for users but there is nothing we can do about it.)

@YooSunYoung
Copy link
Member Author

Ah ha.

I think it'll help if we have that information in the docstring of the FilePath type in essreduce and File object.

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