Open xjmdale opened 5 months ago
Thank you for reporting!
We need to revisit the implementation of relative_to()
. The problem is that relative paths should probably be returned as a custom filesystem independent PurePathBase subclass once we switch to pathlib_abc
.
Would you be interested in creating a PR with a test case for your issue?
Cheers, Andreas
Observed behavior:
The result is not a relative path; it is an absolute path to an alternative GCS object which may or may not exist.
My expectation is that this call would return a fully-relative path to
baz/quux.txt
. I suppose there is uncertainty is around which path subtype should be returned.baz/quux.txt
is not a valid GCS path; butupath.UPath('baz/quux.txt')
returns aPosixUPath
which also seems wrong.Python version: 3.11.7 upath version: 0.1.4