@@ -2549,7 +2549,8 @@ features:
25492549 Windows now handles a *mode * of ``0o700 ``.
25502550
25512551
2552- .. function :: makedirs(name, mode=0o777, exist_ok=False)
2552+ .. function :: makedirs(name, mode=0o777, exist_ok=False, *, \
2553+ parent_mode=None)
25532554
25542555 .. index ::
25552556 single: directory; creating
@@ -2567,6 +2568,12 @@ features:
25672568 If *exist_ok * is ``False `` (the default), a :exc: `FileExistsError ` is
25682569 raised if the target directory already exists.
25692570
2571+ If *parent_mode * is not ``None ``, it is used as the mode for any
2572+ newly-created, intermediate-level directories. Like *mode *, it is
2573+ combined with the process's umask value; see :ref: `the mkdir()
2574+ description <mkdir_modebits>`. Otherwise, intermediate directories are
2575+ created with the default mode, which is also subject to the umask.
2576+
25702577 .. note ::
25712578
25722579 :func: `makedirs ` will become confused if the path elements to create
@@ -2593,6 +2600,11 @@ features:
25932600 The *mode * argument no longer affects the file permission bits of
25942601 newly created intermediate-level directories.
25952602
2603+ .. versionadded :: 3.15
2604+ The *parent_mode * parameter. To match the behavior from Python 3.6 and
2605+ earlier (where *mode * was applied to all created directories), pass
2606+ ``parent_mode=mode ``.
2607+
25962608
25972609.. function :: mkfifo(path, mode=0o666, *, dir_fd=None)
25982610
@@ -5062,6 +5074,18 @@ written in Python, such as a mail server's external command delivery program.
50625074 .. availability :: Linux >= 5.10
50635075 .. versionadded :: 3.12
50645076
5077+ .. function :: pidfd_getfd(pidfd, targetfd, *, flags=0)
5078+
5079+ Duplicate *targetfd * from the process referred to by the process file
5080+ descriptor *pidfd *, into the calling process. The returned file descriptor
5081+ is :ref: `non-inheritable <fd_inheritance >`.
5082+
5083+ *flags * is reserved, and currently must be ``0 ``.
5084+
5085+ See the :manpage: `pidfd_getfd(2)` man page for more details.
5086+
5087+ .. availability :: Linux >= 5.6, Android >= :func:`build-time <sys.getandroidapilevel>` API level 31
5088+ .. versionadded :: next
50655089
50665090.. function :: plock(op, /)
50675091
0 commit comments