@@ -3,12 +3,14 @@ Title: Adding Android as a supported platform
33Author: Malcolm Smith <smith@chaquo.com>
44Sponsor: Petr Viktorin <encukou@gmail.com>
55Discussions-To: https://discuss.python.org/t/pep-738-adding-android-as-a-supported-platform/40975
6- Status: Accepted
6+ Status: Final
77Type: Standards Track
88Created: 12-Dec-2023
99Python-Version: 3.13
1010Resolution: https://discuss.python.org/t/pep-738-adding-android-as-a-supported-platform/40975/23
1111
12+ .. canonical-doc :: :ref:`python:using-android`
13+
1214
1315Abstract
1416========
@@ -289,8 +291,6 @@ namedtuple containing the following:
289291* ``release `` - Android version of the device, as a string (e.g. ``"14" ``)
290292* ``api_level `` - :ref: `API level <738-os-versions >` of the device, as an
291293 integer (e.g. ``34 ``)
292- * ``min_api_level `` - Minimum API level this build of Python can run on, as
293- an integer (e.g. ``23 ``). This is the same as ``sys.getandroidapilevel ``.
294294* ``manufacturer `` - `manufacturer
295295 <https://developer.android.com/reference/android/os/Build#MANUFACTURER> `__ of
296296 the device, as a string (e.g. ``"Google" ``)
@@ -300,6 +300,8 @@ namedtuple containing the following:
300300* ``device `` - `device name
301301 <https://developer.android.com/reference/android/os/Build#DEVICE> `__ of the
302302 device, as a string (e.g. ``"panther" ``)
303+ * ``is_emulator `` - ``True `` if the device is an emulator; ``False `` if it’s a
304+ physical device.
303305
304306Which one of ``model `` and ``device `` is more likely to be unique, and which one
305307is more likely to resemble the marketing name, varies between different
@@ -437,6 +439,20 @@ example of a test suite that is executed on the Android emulator using GitHub
437439Actions.
438440
439441
442+ Rejected Ideas
443+ ==============
444+
445+ The following changes were made to the original specification of
446+ ``platform.android_ver() ``:
447+
448+ * The ``min_api_level `` field was removed, because unlike all the other fields,
449+ it isn't a property of the current device. This information is still available
450+ from the pre-existing function ``sys.getandroidapilevel() ``.
451+
452+ * The ``is_emulator `` field was added, since experience during testing showed
453+ that some issues were emulator-specific.
454+
455+
440456Copyright
441457=========
442458
0 commit comments