I upgraded to UPath 0.3.2 and now I am getting type checking errors with basedpyright because __fspath__ is missing.
import os
from upath import UPath
path = UPath(__file__)
os.remove(path)
Basedpyright outputs:
error: Argument of type "UPath" cannot be assigned to parameter "path" of type "StrOrBytesPath" in function "remove"
Type "UPath" is not assignable to type "StrOrBytesPath"
"UPath" is not assignable to "str"
"UPath" is not assignable to "bytes"
"UPath" is incompatible with protocol "PathLike[str]"
"__fspath__" is not present
"UPath" is incompatible with protocol "PathLike[bytes]"
"__fspath__" is not present (reportArgumentType)
1 error, 0 warnings, 0 notes
Are there any migration instructions I have missed?
I upgraded to UPath 0.3.2 and now I am getting type checking errors with basedpyright because
__fspath__is missing.Basedpyright outputs:
Are there any migration instructions I have missed?