spacetx / slicedimage

MIT License
7 stars 3 forks source link

Fix conversion of file:// URLs to local paths. #88

Closed ttung closed 5 years ago

ttung commented 5 years ago

Previously, we just extracted the path component and used that as the base path for the DiskCache backend. However, on Windows, we need to convert the path separators to forward slashes. We do this by parsing the URL into a posix path, and then creating a local system path from the path components.

Test plan: would be great if this was tested on Windows....

codecov-io commented 5 years ago

Codecov Report

Merging #88 into master will decrease coverage by 0.71%. The diff coverage is 100%.

Impacted file tree graph

@@            Coverage Diff            @@
##           master     #88      +/-   ##
=========================================
- Coverage   76.92%   76.2%   -0.72%     
=========================================
  Files          21      21              
  Lines         741     706      -35     
=========================================
- Hits          570     538      -32     
+ Misses        171     168       -3
Impacted Files Coverage Δ
slicedimage/io.py 77.73% <100%> (+0.34%) :arrow_up:
slicedimage/_compat.py 100% <100%> (ø)
slicedimage/backends/__init__.py 100% <0%> (ø) :arrow_up:
slicedimage/backends/_s3.py

Continue to review full report at Codecov.

Legend - Click here to learn more Δ = absolute <relative> (impact), ø = not affected, ? = missing data Powered by Codecov. Last update 49d91ca...b48dfb2. Read the comment docs.