coerce_to_local_path
coerce_to_local_path(
resource ,
)-> ‘Path’
Return a plain Path for a local resource, stripping any URI scheme.
Path("file:///tmp/x") keeps the scheme as a literal path segment, so local inputs carrying a file:// (or local://) scheme must be routed through UPath first to recover the real filesystem path. Plain paths take a fast path and skip that round-trip.