From 716bd91eef14bf165049497efdd1f90784802e8e Mon Sep 17 00:00:00 2001 From: "Yves.Duprat" Date: Tue, 16 Jun 2026 11:50:04 +0200 Subject: [PATCH 1/5] add ``not macOS`` restriction on availabitity of 7 functions from ``os`` module --- Doc/library/os.rst | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/Doc/library/os.rst b/Doc/library/os.rst index 9327d616ffa05da..890f97975cf52cf 100644 --- a/Doc/library/os.rst +++ b/Doc/library/os.rst @@ -541,7 +541,7 @@ process and user. Return a tuple (ruid, euid, suid) denoting the current process's real, effective, and saved user ids. - .. availability:: Unix, not WASI. + .. availability:: Unix, not WASI, not macOS. .. versionadded:: 3.2 @@ -551,7 +551,7 @@ process and user. Return a tuple (rgid, egid, sgid) denoting the current process's real, effective, and saved group ids. - .. availability:: Unix, not WASI. + .. availability:: Unix, not WASI, not macOS. .. versionadded:: 3.2 @@ -725,7 +725,7 @@ process and user. Set the current process's real, effective, and saved group ids. - .. availability:: Unix, not WASI, not Android. + .. availability:: Unix, not WASI, not Android, not macOS. .. versionadded:: 3.2 @@ -734,7 +734,7 @@ process and user. Set the current process's real, effective, and saved user ids. - .. availability:: Unix, not WASI, not Android. + .. availability:: Unix, not WASI, not Android, not macOS. .. versionadded:: 3.2 @@ -1426,7 +1426,7 @@ or `the MSDN `_ on Windo Return a pair of file descriptors ``(r, w)`` usable for reading and writing, respectively. - .. availability:: Unix, not WASI. + .. availability:: Unix, not WASI, not macOS. .. versionadded:: 3.3 @@ -1436,7 +1436,7 @@ or `the MSDN `_ on Windo Ensures that enough disk space is allocated for the file specified by *fd* starting from *offset* and continuing for *len* bytes. - .. availability:: Unix. + .. availability:: Unix, not macOS. .. versionadded:: 3.3 @@ -1451,7 +1451,7 @@ or `the MSDN `_ on Windo :data:`POSIX_FADV_RANDOM`, :data:`POSIX_FADV_NOREUSE`, :data:`POSIX_FADV_WILLNEED` or :data:`POSIX_FADV_DONTNEED`. - .. availability:: Unix. + .. availability:: Unix, not macOS. .. versionadded:: 3.3 From 0371cbe082a69ed9c6512afae8a5bab91c98c22f Mon Sep 17 00:00:00 2001 From: Duprat Date: Thu, 18 Jun 2026 14:19:09 +0200 Subject: [PATCH 2/5] Update availability notes to include iOS --- Doc/library/os.rst | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/Doc/library/os.rst b/Doc/library/os.rst index 890f97975cf52cf..4af60351fa5e7e7 100644 --- a/Doc/library/os.rst +++ b/Doc/library/os.rst @@ -541,7 +541,7 @@ process and user. Return a tuple (ruid, euid, suid) denoting the current process's real, effective, and saved user ids. - .. availability:: Unix, not WASI, not macOS. + .. availability:: Unix, not WASI, not macOS, not iOS. .. versionadded:: 3.2 @@ -551,7 +551,7 @@ process and user. Return a tuple (rgid, egid, sgid) denoting the current process's real, effective, and saved group ids. - .. availability:: Unix, not WASI, not macOS. + .. availability:: Unix, not WASI, not macOS, not iOS. .. versionadded:: 3.2 @@ -725,7 +725,7 @@ process and user. Set the current process's real, effective, and saved group ids. - .. availability:: Unix, not WASI, not Android, not macOS. + .. availability:: Unix, not WASI, not Android, not macOS, not iOS. .. versionadded:: 3.2 @@ -734,7 +734,7 @@ process and user. Set the current process's real, effective, and saved user ids. - .. availability:: Unix, not WASI, not Android, not macOS. + .. availability:: Unix, not WASI, not Android, not macOS, not iOS. .. versionadded:: 3.2 @@ -1426,7 +1426,7 @@ or `the MSDN `_ on Windo Return a pair of file descriptors ``(r, w)`` usable for reading and writing, respectively. - .. availability:: Unix, not WASI, not macOS. + .. availability:: Unix, not WASI, not macOS, not iOS. .. versionadded:: 3.3 @@ -1436,7 +1436,7 @@ or `the MSDN `_ on Windo Ensures that enough disk space is allocated for the file specified by *fd* starting from *offset* and continuing for *len* bytes. - .. availability:: Unix, not macOS. + .. availability:: Unix, not macOS, not iOS. .. versionadded:: 3.3 @@ -1451,7 +1451,7 @@ or `the MSDN `_ on Windo :data:`POSIX_FADV_RANDOM`, :data:`POSIX_FADV_NOREUSE`, :data:`POSIX_FADV_WILLNEED` or :data:`POSIX_FADV_DONTNEED`. - .. availability:: Unix, not macOS. + .. availability:: Unix, not macOS, not iOS. .. versionadded:: 3.3 From 510ecd27213b651005f246019c8e56092a8c34ea Mon Sep 17 00:00:00 2001 From: "Yves.Duprat" Date: Thu, 18 Jun 2026 21:47:23 +0200 Subject: [PATCH 3/5] add 'not macOS' to os.plock availability --- Doc/library/os.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Doc/library/os.rst b/Doc/library/os.rst index 4af60351fa5e7e7..14b4162f7c51a0c 100644 --- a/Doc/library/os.rst +++ b/Doc/library/os.rst @@ -5107,7 +5107,7 @@ written in Python, such as a mail server's external command delivery program. Lock program segments into memory. The value of *op* (defined in ````) determines which segments are locked. - .. availability:: Unix, not WASI, not iOS. + .. availability:: Unix, not WASI, not macOS, not iOS. .. function:: popen(cmd, mode='r', buffering=-1) From 58ed4eb94c013704671bb6055ebbff6ec62fdf6e Mon Sep 17 00:00:00 2001 From: "Yves.Duprat" Date: Fri, 19 Jun 2026 09:44:10 +0200 Subject: [PATCH 4/5] fix a last nit --- Doc/library/os.rst | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/Doc/library/os.rst b/Doc/library/os.rst index 14b4162f7c51a0c..92b28f8276405b2 100644 --- a/Doc/library/os.rst +++ b/Doc/library/os.rst @@ -1071,10 +1071,7 @@ as internal buffering of data. Force write of file with filedescriptor *fd* to disk. Does not force update of metadata. - .. availability:: Unix. - - .. note:: - This function is not available on MacOS. + .. availability:: Unix, not macOS. .. function:: fpathconf(fd, name, /) From 35708437152d420483e71c39f9957ce4012ef6e9 Mon Sep 17 00:00:00 2001 From: Ned Deily Date: Fri, 19 Jun 2026 03:56:11 -0400 Subject: [PATCH 5/5] not iOS for fdatasync --- Doc/library/os.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Doc/library/os.rst b/Doc/library/os.rst index 92b28f8276405b2..437c4945f5dd5ce 100644 --- a/Doc/library/os.rst +++ b/Doc/library/os.rst @@ -1071,7 +1071,7 @@ as internal buffering of data. Force write of file with filedescriptor *fd* to disk. Does not force update of metadata. - .. availability:: Unix, not macOS. + .. availability:: Unix, not macOS, not iOS. .. function:: fpathconf(fd, name, /)