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 path names with spaces #40

Closed
bertsky opened this issue Apr 2, 2022 · 0 comments
Closed

support path names with spaces #40

bertsky opened this issue Apr 2, 2022 · 0 comments

Comments

@bertsky
Copy link
Contributor

bertsky commented Apr 2, 2022

When opening a workspace with spaces anywhere in the directory names, ocrd_browser fails:

browse-ocrd PRImA\ Layout\ Analysis\ Dataset/mets.xml
FileNotFoundError: File path passed as 'url' to download_to_directory does not exist: /daten/PRImA%20Layout%20Analysis%20Dataset/mets.xml

The cause is not on the OCR-D side AFAICS, but here:

mets_url = cls._strip_local(mets_url)

which in turn does

def _strip_local(mets_url: Union[Path, str], disallow_remote: bool = True) -> str:
result = urlparse(str(mets_url))

@hnesk hnesk closed this as completed in 13459bf Apr 21, 2022
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

1 participant