File tree Expand file tree Collapse file tree 1 file changed +27
-0
lines changed
Expand file tree Collapse file tree 1 file changed +27
-0
lines changed Original file line number Diff line number Diff line change 66from typing import TYPE_CHECKING
77
88from upath ._stat import UPathStatResult
9+ from upath .core import UnsupportedOperation
910from upath .core import UPath
1011from upath .types import JoinablePathLike
1112from upath .types import StatResultType
@@ -41,6 +42,32 @@ def __init__(
4142 ** storage_options : Unpack [TarStorageOptions ],
4243 ) -> None : ...
4344
45+ def touch (self , mode : int = 0o666 , exist_ok : bool = True ) -> None :
46+ raise UnsupportedOperation
47+
48+ def mkdir (
49+ self ,
50+ mode : int = 0o777 ,
51+ parents : bool = False ,
52+ exist_ok : bool = False ,
53+ ) -> None :
54+ raise UnsupportedOperation
55+
56+ def unlink (self , missing_ok : bool = False ) -> None :
57+ raise UnsupportedOperation
58+
59+ def write_bytes (self , data : bytes ) -> int :
60+ raise UnsupportedOperation ("DataPath does not support writing" )
61+
62+ def write_text (
63+ self ,
64+ data : str ,
65+ encoding : str | None = None ,
66+ errors : str | None = None ,
67+ newline : str | None = None ,
68+ ) -> int :
69+ raise UnsupportedOperation ("DataPath does not support writing" )
70+
4471 def stat (
4572 self ,
4673 * ,
You can’t perform that action at this time.
0 commit comments