Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion deepzoom/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -544,7 +544,7 @@ def safe_open(path):
# not a URL. This change is isolated to this function as we want the output
# XML to still have the original input paths instead of absolute paths:
has_scheme = bool(urlparse(path).scheme)
normalized_path = ("file://%s" % os.path.abspath(path)) if not has_scheme else path
normalized_path = ("file:%s" % urllib.request.pathname2url(os.path.abspath(path))) if not has_scheme else path
return io.BytesIO(urllib.request.urlopen(normalized_path).read())


Expand Down