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

Commit43b7f8a

Browse files
committed
Annotate safer_popen broad enough for all platforms
This fixes another static typing error reported by mypy.(The annotation could be made more specific in the future by makinga custom protocol for it, which may or may not be worthwhile, giventhat `**kwargs: Any` would still have to be present after whatevertyped keyword arguments the protocol's `__call__` method listed,since some callers intentionally forward arbitrary extra keywordarguments through safer_popen to Popen.)
1 parent3c5ca52 commit43b7f8a

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

‎git/cmd.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -278,6 +278,8 @@ def _safer_popen_windows(
278278
)
279279

280280

281+
safer_popen:Callable[...,Popen]
282+
281283
ifos.name=="nt":
282284
safer_popen=_safer_popen_windows
283285
else:

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp