Repository navigation
Read and write Windows paths (0.10.3) - #19
Draft
davidackerman wants to merge 5 commits into
Draft
davidackerman wants to merge 5 commits into
davidackerman wants to merge 5 commits into
Conversation
… Windows in CI normalize_path left a Windows path with backslashes, which parent, join, basename and the keys tensorstore appends all split on a forward slash: tensorstore refused the result (Invalid file path).
…pen; the tests' paths as normalize_path writes them
…west on Windows too An array created just under a drive (D:/vol.zarr) found its group in "D:", the drive's working directory: store.parent gives D:/. The spec states the forward slashes and the drive's root. The newest dependencies, what cellmap-flow's Windows CI installs, run on Windows as well. The stalled-write test gave the real write after two stalls 0.03 s, too little on a Windows runner.
A patch: it reads more stores (local paths on Windows, where every local open failed) and places nothing differently.
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
A Windows path (
D:\data\vol.zarr) is normalised to forward slashes, which Windows reads the same and whichparent,join,basenameand tensorstore's own keys split on. A drive's root (D:/) keeps its slash and is a root: never probed, without a parent, and read as holding no document, because tensorstore's file kvstore will not open one (Invalid file path: "C:/"), anddetect's look for a precomputedinfoin the parent reached it from any directory just under a drive. An array created just under a drive (D:/vol.zarr) now looks for its group inD:/, not inD:, the drive's working directory.Before,
normalize_pathleft the backslashes in, and opening any local volume on Windows failed (Invalid file path: "D:\\/"), which is what cellmap-flow's Windows CI job hit (janelia-cellmap/cellmap-flow#212).CI gains
windows-latestin both the lock's and the newest dependencies' jobs, and one test that runs only there. The tests compare paths asnormalize_pathwrites them; the stale-login test is skipped on Windows, whose TLS (Schannel) refuses a test CA with no revocation list; and the stalled-write test gives the real write after two stalls 0.6 s, where 0.03 s was too little on a Windows runner. Linux and the Mac take the code path they did.0.10.3, a patch: it reads more stores and places nothing differently. The spec states the Windows path rules.