On this page
  1. platform.platform
  2. Import
  3. Signature & Overview
  4. Usage
  5. Gotchas
  6. REPL Inspect

platform.platform

Prev: platform.node | Up: platform | Next: platform.processor
Rel: platform.android_ver, platform.AndroidVer, platform.architecture, platform.freedesktop_os_release
Ref: docs.python.org — platform.platform
Tags: #public #python3 #stdlib #platform


Import

import platform
from platform import platform

Signature & Overview

platform.platform(aliased=False, terse=False)

Returns a single string identifying the underlying platform with as much useful information as possible (but no more :).

Usage

import platform

desc = platform.platform(terse=True)
assert isinstance(desc, str) and len(desc) > 0

Gotchas

REPL Inspect

from platform import platform
help(platform)

Linked from

Related notes