Skip to content

Commit 4fb39b6

Browse files
Update type annotation of stderr parameter to make it optional (#835)
1 parent cf82e6d commit 4fb39b6

3 files changed

Lines changed: 8 additions & 8 deletions

File tree

nox/command.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -83,7 +83,7 @@ def run(
8383
log: bool = True,
8484
external: ExternalType = False,
8585
stdout: int | IO[str] | None = None,
86-
stderr: int | IO[str] = subprocess.STDOUT,
86+
stderr: int | IO[str] | None = subprocess.STDOUT,
8787
interrupt_timeout: float | None = DEFAULT_INTERRUPT_TIMEOUT,
8888
terminate_timeout: float | None = DEFAULT_TERMINATE_TIMEOUT,
8989
) -> str | bool:

nox/popen.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,7 @@ def popen(
6666
env: Mapping[str, str] | None = None,
6767
silent: bool = False,
6868
stdout: int | IO[str] | None = None,
69-
stderr: int | IO[str] = subprocess.STDOUT,
69+
stderr: int | IO[str] | None = subprocess.STDOUT,
7070
interrupt_timeout: float | None = DEFAULT_INTERRUPT_TIMEOUT,
7171
terminate_timeout: float | None = DEFAULT_TERMINATE_TIMEOUT,
7272
) -> tuple[int, str]:

nox/sessions.py

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -294,7 +294,7 @@ def run(
294294
log: bool = True,
295295
external: ExternalType | None = None,
296296
stdout: int | IO[str] | None = None,
297-
stderr: int | IO[str] = subprocess.STDOUT,
297+
stderr: int | IO[str] | None = subprocess.STDOUT,
298298
interrupt_timeout: float | None = DEFAULT_INTERRUPT_TIMEOUT,
299299
terminate_timeout: float | None = DEFAULT_TERMINATE_TIMEOUT,
300300
) -> Any | None:
@@ -433,7 +433,7 @@ def run_install(
433433
log: bool = True,
434434
external: ExternalType | None = None,
435435
stdout: int | IO[str] | None = None,
436-
stderr: int | IO[str] = subprocess.STDOUT,
436+
stderr: int | IO[str] | None = subprocess.STDOUT,
437437
interrupt_timeout: float | None = DEFAULT_INTERRUPT_TIMEOUT,
438438
terminate_timeout: float | None = DEFAULT_TERMINATE_TIMEOUT,
439439
) -> Any | None:
@@ -515,7 +515,7 @@ def run_always(
515515
log: bool = True,
516516
external: ExternalType | None = None,
517517
stdout: int | IO[str] | None = None,
518-
stderr: int | IO[str] = subprocess.STDOUT,
518+
stderr: int | IO[str] | None = subprocess.STDOUT,
519519
interrupt_timeout: float | None = DEFAULT_INTERRUPT_TIMEOUT,
520520
terminate_timeout: float | None = DEFAULT_TERMINATE_TIMEOUT,
521521
) -> Any | None:
@@ -548,7 +548,7 @@ def _run(
548548
log: bool,
549549
external: ExternalType | None,
550550
stdout: int | IO[str] | None,
551-
stderr: int | IO[str],
551+
stderr: int | IO[str] | None,
552552
interrupt_timeout: float | None,
553553
terminate_timeout: float | None,
554554
) -> Any:
@@ -611,7 +611,7 @@ def conda_install(
611611
success_codes: Iterable[int] | None = None,
612612
log: bool = True,
613613
stdout: int | IO[str] | None = None,
614-
stderr: int | IO[str] = subprocess.STDOUT,
614+
stderr: int | IO[str] | None = subprocess.STDOUT,
615615
interrupt_timeout: float | None = DEFAULT_INTERRUPT_TIMEOUT,
616616
terminate_timeout: float | None = DEFAULT_TERMINATE_TIMEOUT,
617617
) -> None:
@@ -718,7 +718,7 @@ def install(
718718
log: bool = True,
719719
external: ExternalType | None = None,
720720
stdout: int | IO[str] | None = None,
721-
stderr: int | IO[str] = subprocess.STDOUT,
721+
stderr: int | IO[str] | None = subprocess.STDOUT,
722722
interrupt_timeout: float | None = DEFAULT_INTERRUPT_TIMEOUT,
723723
terminate_timeout: float | None = DEFAULT_TERMINATE_TIMEOUT,
724724
) -> None:

0 commit comments

Comments
 (0)