File tree Expand file tree Collapse file tree 1 file changed +8
-6
lines changed Expand file tree Collapse file tree 1 file changed +8
-6
lines changed Original file line number Diff line number Diff line change 1
1
import sys
2
2
from typing import Callable , Iterable
3
+ from typing_extensions import Literal
3
4
4
5
if sys .platform != "win32" :
6
+ __all__ = ["openpty" , "fork" , "spawn" ]
5
7
_Reader = Callable [[int ], bytes ]
6
8
7
- STDIN_FILENO : int
8
- STDOUT_FILENO : int
9
- STDERR_FILENO : int
9
+ STDIN_FILENO : Literal [ 0 ]
10
+ STDOUT_FILENO : Literal [ 1 ]
11
+ STDERR_FILENO : Literal [ 2 ]
10
12
11
- CHILD : int
13
+ CHILD : Literal [ 0 ]
12
14
def openpty () -> tuple [int , int ]: ...
13
- def master_open () -> tuple [int , str ]: ...
14
- def slave_open (tty_name : str ) -> int : ...
15
+ def master_open () -> tuple [int , str ]: ... # deprecated, use openpty()
16
+ def slave_open (tty_name : str ) -> int : ... # deprecated, use openpty()
15
17
def fork () -> tuple [int , int ]: ...
16
18
def spawn (argv : str | Iterable [str ], master_read : _Reader = ..., stdin_read : _Reader = ...) -> int : ...
You can’t perform that action at this time.
0 commit comments