Skip to content

bpo-41203: Replace OS X with macOS #21316

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 10 commits into from
6 changes: 3 additions & 3 deletions Doc/c-api/init.rst
Original file line number Diff line number Diff line change
Expand Up @@ -448,7 +448,7 @@ Process-wide parameters
(set by :c:func:`Py_SetProgramName` above) and some environment variables.
The returned string consists of a series of directory names separated by a
platform dependent delimiter character. The delimiter character is ``':'``
on Unix and Mac OS X, ``';'`` on Windows. The returned string points into
on Unix and macOS, ``';'`` on Windows. The returned string points into
static storage; the caller should not modify its value. The list
:data:`sys.path` is initialized with this value on interpreter startup; it
can be (and usually is) modified later to change the search path for loading
Expand All @@ -469,7 +469,7 @@ Process-wide parameters
default search path but uses the one provided instead. This is useful if
Python is embedded by an application that has full knowledge of the location
of all modules. The path components should be separated by the platform
dependent delimiter character, which is ``':'`` on Unix and Mac OS X, ``';'``
dependent delimiter character, which is ``':'`` on Unix and macOS, ``';'``
on Windows.

This also causes :data:`sys.executable` to be set to the program
Expand Down Expand Up @@ -510,7 +510,7 @@ Process-wide parameters
Return the platform identifier for the current platform. On Unix, this is
formed from the "official" name of the operating system, converted to lower
case, followed by the major revision number; e.g., for Solaris 2.x, which is
also known as SunOS 5.x, the value is ``'sunos5'``. On Mac OS X, it is
also known as SunOS 5.x, the value is ``'sunos5'``. On macOS, it is
``'darwin'``. On Windows, it is ``'win'``. The returned string points into
static storage; the caller should not modify its value. The value is available
to Python code as ``sys.platform``.
Expand Down
2 changes: 1 addition & 1 deletion Doc/distributing/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,7 @@ by invoking the ``pip`` module at the command line::

.. note::

For POSIX users (including Mac OS X and Linux users), these instructions
For POSIX users (including macOS and Linux users), these instructions
assume the use of a :term:`virtual environment`.

For Windows users, these instructions assume that the option to
Expand Down
8 changes: 4 additions & 4 deletions Doc/distutils/apiref.rst
Original file line number Diff line number Diff line change
Expand Up @@ -373,7 +373,7 @@ This module provides the following functions.
compiler object under Unix---if you supply a value for *compiler*, *plat* is
ignored.

.. % Is the posix/nt only thing still true? Mac OS X seems to work, and
.. % Is the posix/nt only thing still true? macOS seems to work, and
.. % returns a UnixCCompiler instance. How to document this... hmm.


Expand Down Expand Up @@ -1119,11 +1119,11 @@ other utility module.

For non-POSIX platforms, currently just returns ``sys.platform``.

For Mac OS X systems the OS version reflects the minimal version on which
For macOS systems the OS version reflects the minimal version on which
binaries will run (that is, the value of ``MACOSX_DEPLOYMENT_TARGET``
during the build of Python), not the OS version of the current system.

For universal binary builds on Mac OS X the architecture value reflects
For universal binary builds on macOS the architecture value reflects
the universal binary status instead of the architecture of the current
processor. For 32-bit universal binaries the architecture is ``fat``,
for 64-bit universal binaries the architecture is ``fat64``, and
Expand All @@ -1132,7 +1132,7 @@ other utility module.
a 3-way universal build (ppc, i386, x86_64) and ``intel`` is used for
a universal build with the i386 and x86_64 architectures

Examples of returned values on Mac OS X:
Examples of returned values on macOS:

* ``macosx-10.3-ppc``

Expand Down
2 changes: 1 addition & 1 deletion Doc/extending/extending.rst
Original file line number Diff line number Diff line change
Expand Up @@ -914,7 +914,7 @@ The :mod:`gc` module exposes a way to run the detector (the
interfaces and the ability to disable the detector at runtime. The cycle
detector is considered an optional component; though it is included by default,
it can be disabled at build time using the :option:`!--without-cycle-gc` option
to the :program:`configure` script on Unix platforms (including Mac OS X). If
to the :program:`configure` script on Unix platforms (including macOS). If
the cycle detector is disabled in this way, the :mod:`gc` module will not be
available.

Expand Down
6 changes: 3 additions & 3 deletions Doc/faq/gui.rst
Original file line number Diff line number Diff line change
Expand Up @@ -32,14 +32,14 @@ install (since it comes included with most
`binary distributions <https://www.python.org/downloads/>`_ of Python) and use.
For more info about Tk, including pointers to the source, see the
`Tcl/Tk home page <https://www.tcl.tk>`_. Tcl/Tk is fully portable to the
Mac OS X, Windows, and Unix platforms.
macOS, Windows, and Unix platforms.

wxWidgets
---------

wxWidgets (https://www.wxwidgets.org) is a free, portable GUI class
library written in C++ that provides a native look and feel on a
number of platforms, with Windows, Mac OS X, GTK, X11, all listed as
number of platforms, with Windows, macOS, GTK, X11, all listed as
current stable targets. Language bindings are available for a number
of languages including Python, Perl, Ruby, etc.

Expand Down Expand Up @@ -104,7 +104,7 @@ What platform-specific GUI toolkits exist for Python?
========================================================

By installing the `PyObjc Objective-C bridge
<https://pypi.org/project/pyobjc/>`_, Python programs can use Mac OS X's
<https://pypi.org/project/pyobjc/>`_, Python programs can use macOS's
Cocoa libraries.

:ref:`Pythonwin <windows-faq>` by Mark Hammond includes an interface to the
Expand Down
2 changes: 1 addition & 1 deletion Doc/faq/installed.rst
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ there are several possible ways it could have gotten there.
* Some Windows machines also have Python installed. At this writing we're aware
of computers from Hewlett-Packard and Compaq that include Python. Apparently
some of HP/Compaq's administrative tools are written in Python.
* Many Unix-compatible operating systems, such as Mac OS X and some Linux
* Many Unix-compatible operating systems, such as macOS and some Linux
distributions, have Python installed by default; it's included in the base
installation.

Expand Down
8 changes: 4 additions & 4 deletions Doc/install/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -199,7 +199,7 @@ directory.
If you don't choose an installation directory---i.e., if you just run ``setup.py
install``\ ---then the :command:`install` command installs to the standard
location for third-party Python modules. This location varies by platform and
by how you built/installed Python itself. On Unix (and Mac OS X, which is also
by how you built/installed Python itself. On Unix (and macOS, which is also
Unix-based), it also depends on whether the module distribution being installed
is pure Python or contains extensions ("non-pure"):

Expand Down Expand Up @@ -229,7 +229,7 @@ Notes:

:file:`{prefix}` and :file:`{exec-prefix}` stand for the directories that Python
is installed to, and where it finds its libraries at run-time. They are always
the same under Windows, and very often the same under Unix and Mac OS X. You
the same under Windows, and very often the same under Unix and macOS. You
can find out what your Python installation uses for :file:`{prefix}` and
:file:`{exec-prefix}` by running Python in interactive mode and typing a few
simple commands. Under Unix, just type ``python`` at the shell prompt. Under
Expand Down Expand Up @@ -305,7 +305,7 @@ install into it. It is enabled with a simple option::
Files will be installed into subdirectories of :data:`site.USER_BASE` (written
as :file:`{userbase}` hereafter). This scheme installs pure Python modules and
extension modules in the same location (also known as :data:`site.USER_SITE`).
Here are the values for UNIX, including Mac OS X:
Here are the values for UNIX, including macOS:

=============== ===========================================================
Type of file Installation directory
Expand Down Expand Up @@ -728,7 +728,7 @@ Location and names of config files
----------------------------------

The names and locations of the configuration files vary slightly across
platforms. On Unix and Mac OS X, the three configuration files (in the order
platforms. On Unix and macOS, the three configuration files (in the order
they are processed) are:

+--------------+----------------------------------------------------------+-------+
Expand Down
6 changes: 3 additions & 3 deletions Doc/installing/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@ dependencies from the Python Packaging Index::

.. note::

For POSIX users (including Mac OS X and Linux users), the examples in
For POSIX users (including macOS and Linux users), the examples in
this guide assume the use of a :term:`virtual environment`.

For Windows users, the examples in this guide assume that the option to
Expand Down Expand Up @@ -163,7 +163,7 @@ rather than attempting to install them with ``pip``.
... work with multiple versions of Python installed in parallel?
----------------------------------------------------------------

On Linux, Mac OS X, and other POSIX systems, use the versioned Python commands
On Linux, macOS, and other POSIX systems, use the versioned Python commands
in combination with the ``-m`` switch to run the appropriate copy of
``pip``::

Expand Down Expand Up @@ -225,7 +225,7 @@ users being expected to compile extension modules from source as part of
the installation process.

With the introduction of support for the binary ``wheel`` format, and the
ability to publish wheels for at least Windows and Mac OS X through the
ability to publish wheels for at least Windows and macOS through the
Python Packaging Index, this problem is expected to diminish over time,
as users are more regularly able to install pre-built extensions rather
than needing to build them themselves.
Expand Down
6 changes: 3 additions & 3 deletions Doc/library/ctypes.rst
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ ctypes tutorial

Note: The code samples in this tutorial use :mod:`doctest` to make sure that
they actually work. Since some code samples behave differently under Linux,
Windows, or Mac OS X, they contain doctest directives in comments.
Windows, or macOS, they contain doctest directives in comments.

Note: Some code samples reference the ctypes :class:`c_int` type. On platforms
where ``sizeof(long) == sizeof(int)`` it is an alias to :class:`c_long`.
Expand Down Expand Up @@ -80,7 +80,7 @@ the library by creating an instance of CDLL by calling the constructor::
<CDLL 'libc.so.6', handle ... at ...>
>>>

.. XXX Add section for Mac OS X.
.. XXX Add section for macOS.


.. _ctypes-accessing-functions-from-loaded-dlls:
Expand Down Expand Up @@ -1288,7 +1288,7 @@ Here are some examples::
'libbz2.so.1.0'
>>>

On OS X, :func:`find_library` tries several predefined naming schemes and paths
On macOS, :func:`find_library` tries several predefined naming schemes and paths
to locate the library, and returns a full pathname if successful::

>>> from ctypes.util import find_library
Expand Down
2 changes: 1 addition & 1 deletion Doc/library/intro.rst
Original file line number Diff line number Diff line change
Expand Up @@ -58,5 +58,5 @@ Notes on availability
operating system.

* If not separately noted, all functions that claim "Availability: Unix" are
supported on Mac OS X, which builds on a Unix core.
supported on macOS, which builds on a Unix core.

2 changes: 1 addition & 1 deletion Doc/library/mmap.rst
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,7 @@ To map anonymous memory, -1 should be passed as the fileno along with the length

To ensure validity of the created memory mapping the file specified
by the descriptor *fileno* is internally automatically synchronized
with physical backing store on Mac OS X and OpenVMS.
with physical backing store on macOS and OpenVMS.

This example shows a simple way of using :class:`~mmap.mmap`::

Expand Down
6 changes: 3 additions & 3 deletions Doc/library/multiprocessing.rst
Original file line number Diff line number Diff line change
Expand Up @@ -782,7 +782,7 @@ For an example of the usage of queues for interprocess communication see
multithreading/multiprocessing semantics, this number is not reliable.

Note that this may raise :exc:`NotImplementedError` on Unix platforms like
Mac OS X where ``sem_getvalue()`` is not implemented.
macOS where ``sem_getvalue()`` is not implemented.

.. method:: empty()

Expand Down Expand Up @@ -1232,7 +1232,7 @@ object -- see :ref:`multiprocessing-managers`.
first argument is named *block*, as is consistent with :meth:`Lock.acquire`.

.. note::
On Mac OS X, this is indistinguishable from :class:`Semaphore` because
On macOS, this is indistinguishable from :class:`Semaphore` because
``sem_getvalue()`` is not implemented on that platform.

.. class:: Condition([lock])
Expand Down Expand Up @@ -1371,7 +1371,7 @@ object -- see :ref:`multiprocessing-managers`.

.. note::

On Mac OS X, ``sem_timedwait`` is unsupported, so calling ``acquire()`` with
On macOS, ``sem_timedwait`` is unsupported, so calling ``acquire()`` with
a timeout will emulate that function's behavior using a sleeping loop.

.. note::
Expand Down
10 changes: 5 additions & 5 deletions Doc/library/os.rst
Original file line number Diff line number Diff line change
Expand Up @@ -126,7 +126,7 @@ process and user.

.. note::

On some platforms, including FreeBSD and Mac OS X, setting ``environ`` may
On some platforms, including FreeBSD and macOS, setting ``environ`` may
cause memory leaks. Refer to the system documentation for
:c:func:`putenv`.

Expand Down Expand Up @@ -448,7 +448,7 @@ process and user.

.. note::

On some platforms, including FreeBSD and Mac OS X, setting ``environ`` may
On some platforms, including FreeBSD and macOS, setting ``environ`` may
cause memory leaks. Refer to the system documentation for :c:func:`putenv`.

.. audit-event:: os.putenv key,value os.putenv
Expand Down Expand Up @@ -1295,11 +1295,11 @@ or `the MSDN <https://msdn.microsoft.com/en-us/library/z0kc8e3z.aspx>`_ on Windo
On Linux, if *offset* is given as ``None``, the bytes are read from the
current position of *in_fd* and the position of *in_fd* is updated.

The second case may be used on Mac OS X and FreeBSD where *headers* and
The second case may be used on macOS and FreeBSD where *headers* and
*trailers* are arbitrary sequences of buffers that are written before and
after the data from *in_fd* is written. It returns the same as the first case.

On Mac OS X and FreeBSD, a value of ``0`` for *count* specifies to send until
On macOS and FreeBSD, a value of ``0`` for *count* specifies to send until
the end of *in_fd* is reached.

All platforms support sockets as *out_fd* file descriptor, and some platforms
Expand Down Expand Up @@ -2667,7 +2667,7 @@ features:
String that uniquely identifies the type of the filesystem that
contains the file.

On Mac OS systems, the following attributes may also be available:
On macOS systems, the following attributes may also be available:

.. attribute:: st_rsize

Expand Down
6 changes: 3 additions & 3 deletions Doc/library/othergui.rst
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
Other Graphical User Interface Packages
=======================================

Major cross-platform (Windows, Mac OS X, Unix-like) GUI toolkits are
Major cross-platform (Windows, macOS, Unix-like) GUI toolkits are
available for Python:

.. seealso::
Expand All @@ -26,7 +26,7 @@ available for Python:
`PyQt <https://riverbankcomputing.com/software/pyqt/intro>`_
PyQt is a :program:`sip`\ -wrapped binding to the Qt toolkit. Qt is an
extensive C++ GUI application development framework that is
available for Unix, Windows and Mac OS X. :program:`sip` is a tool
available for Unix, Windows and macOS. :program:`sip` is a tool
for generating bindings for C++ libraries as Python classes, and
is specifically designed for Python.

Expand All @@ -40,7 +40,7 @@ available for Python:
wxPython is a cross-platform GUI toolkit for Python that is built around
the popular `wxWidgets <https://www.wxwidgets.org/>`_ (formerly wxWindows)
C++ toolkit. It provides a native look and feel for applications on
Windows, Mac OS X, and Unix systems by using each platform's native
Windows, macOS, and Unix systems by using each platform's native
widgets where ever possible, (GTK+ on Unix-like systems). In addition to
an extensive set of widgets, wxPython provides classes for online
documentation and context sensitive help, printing, HTML viewing,
Expand Down
6 changes: 3 additions & 3 deletions Doc/library/platform.rst
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ Cross Platform

.. note::

On Mac OS X (and perhaps other platforms), executable files may be
On macOS (and perhaps other platforms), executable files may be
universal files containing multiple architectures.

To get at the "64-bitness" of the current interpreter, it is more
Expand Down Expand Up @@ -232,13 +232,13 @@ Windows Platform
.. versionadded:: 3.8


Mac OS Platform
macOS Platform
---------------
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The length of the underlying line should be corrected.



.. function:: mac_ver(release='', versioninfo=('','',''), machine='')

Get Mac OS version information and return it as tuple ``(release, versioninfo,
Get macOS version information and return it as tuple ``(release, versioninfo,
machine)`` with *versioninfo* being a tuple ``(version, dev_stage,
non_release_version)``.

Expand Down
2 changes: 1 addition & 1 deletion Doc/library/profile.rst
Original file line number Diff line number Diff line change
Expand Up @@ -622,7 +622,7 @@ procedure can be used to obtain a better constant for a given platform (see
The method executes the number of Python calls given by the argument, directly
and again under the profiler, measuring the time for both. It then computes the
hidden overhead per profiler event, and returns that as a float. For example,
on a 1.8Ghz Intel Core i5 running Mac OS X, and using Python's time.process_time() as
on a 1.8Ghz Intel Core i5 running macOS, and using Python's time.process_time() as
the timer, the magical number is about 4.04e-6.

The object of this exercise is to get a fairly consistent result. If your
Expand Down
4 changes: 2 additions & 2 deletions Doc/library/select.rst
Original file line number Diff line number Diff line change
Expand Up @@ -534,7 +534,7 @@ https://www.freebsd.org/cgi/man.cgi?query=kqueue&sektion=2
| :const:`KQ_FILTER_PROC` | Watch for events on a process id |
+---------------------------+---------------------------------------------+
| :const:`KQ_FILTER_NETDEV` | Watch for events on a network device |
| | [not available on Mac OS X] |
| | [not available on macOS] |
+---------------------------+---------------------------------------------+
| :const:`KQ_FILTER_SIGNAL` | Returns whenever the watched signal is |
| | delivered to the process |
Expand Down Expand Up @@ -626,7 +626,7 @@ https://www.freebsd.org/cgi/man.cgi?query=kqueue&sektion=2
| :const:`KQ_NOTE_TRACKERR` | unable to attach to a child |
+----------------------------+--------------------------------------------+

:const:`KQ_FILTER_NETDEV` filter flags (not available on Mac OS X):
:const:`KQ_FILTER_NETDEV` filter flags (not available on macOS):

+----------------------------+--------------------------------------------+
| Constant | Meaning |
Expand Down
8 changes: 4 additions & 4 deletions Doc/library/site.rst
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ It starts by constructing up to four directories from a head and a tail part.
For the head part, it uses ``sys.prefix`` and ``sys.exec_prefix``; empty heads
are skipped. For the tail part, it uses the empty string and then
:file:`lib/site-packages` (on Windows) or
:file:`lib/python{X.Y}/site-packages` (on Unix and Macintosh). For each
:file:`lib/python{X.Y}/site-packages` (on Unix and Mac). For each
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

macOS

of the distinct head-tail combinations, it sees if it refers to an existing
directory, and if so, adds it to ``sys.path`` and also inspects the newly
added path for configuration files.
Expand Down Expand Up @@ -176,8 +176,8 @@ Module contents

Path to the user site-packages for the running Python. Can be ``None`` if
:func:`getusersitepackages` hasn't been called yet. Default value is
:file:`~/.local/lib/python{X.Y}/site-packages` for UNIX and non-framework Mac
OS X builds, :file:`~/Library/Python/{X.Y}/lib/python/site-packages` for Mac
:file:`~/.local/lib/python{X.Y}/site-packages` for UNIX and non-framework
macOS builds, :file:`~/Library/Python/{X.Y}/lib/python/site-packages` for Mac
framework builds, and :file:`{%APPDATA%}\\Python\\Python{XY}\\site-packages`
on Windows. This directory is a site directory, which means that
:file:`.pth` files in it will be processed.
Expand All @@ -187,7 +187,7 @@ Module contents

Path to the base directory for the user site-packages. Can be ``None`` if
:func:`getuserbase` hasn't been called yet. Default value is
:file:`~/.local` for UNIX and Mac OS X non-framework builds,
:file:`~/.local` for UNIX and macOS non-framework builds,
:file:`~/Library/Python/{X.Y}` for Mac framework builds, and
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What is the correct name?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think this still applies to current macOS

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

macOS?

:file:`{%APPDATA%}\\Python` for Windows. This value is used by Distutils to
compute the installation directories for scripts, data files, Python modules,
Expand Down
Loading