On this page
platform.release
Prev: platform.python_version_tuple | Up: platform | Next: platform.system
Rel: platform.android_ver, platform.AndroidVer, platform.architecture, platform.freedesktop_os_release
Ref: docs.python.org — platform.release
Tags: #public #python3 #stdlib #platform
Import
import platform
from platform import release
Signature & Overview
platform.release()
Returns the system's release, e.g. '2.2.0' or 'NT' An empty string is returned if the value cannot be determined.
Usage
import platform
assert isinstance(platform.release(), str)
Gotchas
- Kernel/OS release string (e.g.,
"24.1.0"on macOS Darwin,"11"on Windows).
REPL Inspect
from platform import release
help(release)
Linked from
Related notes
- tuts/python3/stdlib_module/platform/python_version_tuple Linked here; links to this page; shared tags: #platform, #stdlib
- tuts/python3/stdlib_module/platform/system Linked here; links to this page; shared tags: #platform, #stdlib
- tuts/python3/stdlib_module/platform/android_ver Linked here; shared tags: #platform, #stdlib
- tuts/python3/stdlib_module/platform/AndroidVer Linked here; shared tags: #platform, #stdlib
- tuts/python3/stdlib_module/platform/architecture Linked here; shared tags: #platform, #stdlib
- tuts/python3/stdlib_module/platform/freedesktop_os_release Linked here; shared tags: #platform, #stdlib
- tuts/python3/stdlib_module/platform/platform Linked here; shared tags: #platform, #stdlib
- tuts/python3/stdlib_module/platform links to this page; shared tags: #stdlib
- tuts/python3/stdlib_module/platform/invalidate_caches shared tags: #platform, #stdlib
- tuts/python3/stdlib_module/platform/ios_ver shared tags: #platform, #stdlib