Filesystem caps reject slash paths, but glob() returns them #15
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
The first error of the "self-hosted goo" session was:
The working form is a segment array:
readText(['packages','daemon','src','interfaces.js']).The trap is that
glob()on the same capability returns slash-joinedstrings, which
readTextandstatthen refuse. Round-tripping a globresult through a read is a guaranteed error:
list()takes varargs segments whilereadText()takes an array, so whichform to use is a coin flip per method; guessing
list('a','b','c')wrongproduces a bare ENOENT rather than a shape complaint.
Wanted: accept slash strings everywhere (splitting internally), or have
globreturn segment arrays. Either way, one convention across thefilesystem interface.
Fixed in
9d0f61b, live since generation 42. Path arguments are split into segments once, innormalizeSegmentsandresolveSegments, so a slash-joined string and a segment array name the same path across the whole mount surface and aglob()result feeds straight back intoreadText..and..still normalize per segment (so..stays clamped at the confinement root) and denied names inside a joined path are still refused. Verified live:E(src).readText("packages/daemon/src/interfaces.js")- the exact call from this issue - now resolves.