1 parent 41b9faa commit 45eed51Copy full SHA for 45eed51
1 file changed
src/mcp/server/stdio.py
@@ -29,7 +29,7 @@ async def run_server():
29
from mcp.shared.message import SessionMessage
30
31
if sys.platform != "win32": # pragma: no branch
32
- import fcntl
+ import fcntl # pragma: lax no cover - POSIX-only line, uncovered on Windows runners
33
34
# Stream-claim contract (design and attack log in PR #3117):
35
# - _claims is the single authority for who owns fd 0/1; mutated only under the
@@ -64,7 +64,7 @@ def _dup_above_std(fd: int) -> int:
64
os.close(duplicate)
65
raise OSError(f"duplicate of fd {fd} landed in the standard range")
66
return duplicate
67
- return fcntl.fcntl(fd, fcntl.F_DUPFD_CLOEXEC, 3)
+ return fcntl.fcntl(fd, fcntl.F_DUPFD_CLOEXEC, 3) # pragma: lax no cover - POSIX-only
68
69
70
def _open_stdin_diversion() -> int:
0 commit comments