Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit8a93fa7

Browse files
os.popen: add encoding argument for 3.11
python/cpython#92374
1 parente8b3619 commit8a93fa7

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

‎stdlib/os/__init__.pyi‎

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -861,7 +861,10 @@ class _wrap_close(_TextIOWrapper):
861861
def__init__(self,stream:_TextIOWrapper,proc:Popen[str])->None: ...
862862
defclose(self)->int|None: ...# type: ignore[override]
863863

864-
defpopen(cmd:str,mode:str= ...,buffering:int= ...)->_wrap_close: ...
864+
ifsys.version_info>= (3,11):
865+
defpopen(cmd:str,mode:str= ...,buffering:int= ...,encoding:str|None= ...)->_wrap_close: ...
866+
else:
867+
defpopen(cmd:str,mode:str= ...,buffering:int= ...)->_wrap_close: ...
865868
defspawnl(mode:int,file:StrOrBytesPath,arg0:StrOrBytesPath,*args:StrOrBytesPath)->int: ...
866869
defspawnle(mode:int,file:StrOrBytesPath,arg0:StrOrBytesPath,*args:Any)->int: ...# Imprecise sig
867870

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp