$npx skillfedfor your agent

distro

Distro - an OS platform information API

Worth itPyPI Python ModulesReleased Dec 2023417.9M downloads / moApache License, Version 2.0Pure Python

Decision gist · record as of 2026-08-14

pure-Python wheel — distro-1.9.0-py3-none-any.whl
v1.9.0 · released 2023-12-24 · Python >=3.6

Yes. Distro is a stable, zero-dependency library addressing a real need created by Python's removal of `platform.linux_distribution()`. It has active maintenance, no known vulnerabilities, permissive licensing, and is in the top 1000 PyPI packages by download volume. Install it if you need to detect or report the Linux/BSD distribution your code runs on.AI-flagged interpretation of the facts on this page — verify before relying

Before you install

  • Requires Python 3.6+; designed for Linux and BSD systems (Windows and OS X support planned but not yet implemented).
  • Low install friction; pure Python wheel with no runtime dependencies.
  • Active maintenance with last commit 2026-07-22 and stable production status.

License · maintenance · safety

Apache License, Version 2.0 (permissive) — Apache License 2.0 (permissive); safe to use in proprietary and open-source projects without copyleft obligations.

last release 2023-12-24 (964 days) · last repo commit 2026-07-22 · 281 stars

0 known vulnerabilities (OSV.dev, 2026-08-14) · 417,850,387 downloads/mo, #101 on PyPI

Verify before relying

pip install distro

import distro
print(distro.name(pretty=True))
print(distro.id())
print(distro.version(best=True))
  • Whether Windows and OS X support has been added since the description excerpt was written.
  • Current test coverage across the Linux distributions listed in the repository.
Same gist for agents: .md · .json

What it is and what it does

Distro is a lightweight Python library that queries your operating system to retrieve reliable, machine-readable information about the Linux or BSD distribution running on the host—such as the distribution name, version, codename, and release details. It was created as a direct replacement for Python's `platform.linux_distribution()` function, which was deprecated in Python 3.5 and removed entirely in Python 3.8. The library works by checking multiple data sources in order of precedence: `/etc/os-release`, the `lsb_release` command, distro release files, and `uname` for BSD systems.

You use distro when you need to programmatically detect what Linux or BSD distribution your code is running on—for example, in system administration tools, deployment scripts, or applications that need to adapt behavior based on the host OS. It has no runtime dependencies, installs as a pure Python wheel, and can even be vendored directly into projects that want to avoid adding a dependency. The package is actively maintained, tested against Python 3.6 through 3.12, and widely used in infrastructure and configuration management tools.

Use it for

  • Detect the host Linux distribution in deployment or provisioning scripts to apply distribution-specific configuration.
  • Adapt application behavior at runtime based on whether it's running on CentOS, Ubuntu, Debian, or another distribution.
  • Replace deprecated `platform.linux_distribution()` calls in legacy Python code migrating to Python 3.8+.
  • Build system administration tools that need reliable OS identification across heterogeneous Linux and BSD environments.
  • Query OS details from the command line using the standalone `distro` CLI tool for shell scripts.

Worth the install?

AI-flagged interpretation of the facts on this page. Verify before relying on it.

Worth it

Yes.

Distro is a stable, zero-dependency library addressing a real need created by Python's removal of `platform.linux_distribution()`. It has active maintenance, no known vulnerabilities, permissive licensing, and is in the top 1000 PyPI packages by download volume. Install it if you need to detect or report the Linux/BSD distribution your code runs on.

Install

distro on PyPI

Before you install

Low install friction; pure Python wheel with no runtime dependencies. Active maintenance with last commit 2026-07-22 and stable production status.

Requires Python 3.6+; designed for Linux and BSD systems (Windows and OS X support planned but not yet implemented).

License in practice

Apache License 2.0 (permissive); safe to use in proprietary and open-source projects without copyleft obligations.

Quickstart

pip install distro

import distro
print(distro.name(pretty=True))
print(distro.id())
print(distro.version(best=True))

Verify before relying

  • Whether Windows and OS X support has been added since the description excerpt was written.
  • Current test coverage across the Linux distributions listed in the repository.

Package facts

LicenseApache License, Version 2.0 permissive
Python supportSupports the current Python release >=3.6
Install frictionLow. Pure-Python wheel
Runtime dependenciesNone
MaintenanceActively maintained 964 days since the last release
Last repo commit
First released
Downloads417,850,387 / month, #101 on PyPI 30-day window, as of 2026-08-14
Known vulnerabilitiesNone known OSV.dev, checked 2026-08-14
Classifiers
Development Status :: 5 - Production/StableIntended Audience :: DevelopersIntended Audience :: System AdministratorsLicense :: OSI Approved :: Apache Software LicenseOperating System :: POSIX :: BSDOperating System :: POSIX :: BSD :: FreeBSDOperating System :: POSIX :: BSD :: NetBSDOperating System :: POSIX :: BSD :: OpenBSDOperating System :: POSIX :: LinuxProgramming Language :: Python :: 3Programming Language :: Python :: 3 :: OnlyProgramming Language :: Python :: 3.10Programming Language :: Python :: 3.11Programming Language :: Python :: 3.12Programming Language :: Python :: 3.6Programming Language :: Python :: 3.7Programming Language :: Python :: 3.8Programming Language :: Python :: 3.9Topic :: Software Development :: Libraries :: Python ModulesTopic :: System :: Operating System

Evidence: distro-1.9.0-py3-none-any.whl

Tags

Capabilities
linux distribution detectionos platform informationdistro name and versionreplace platform.linux_distributionbsd system identificationmachine-readable os detailslinux release information
Topics
system-infoos-detection

Let your AI agent find packages like this

Example. Real query, live index.

You found this page by searching. An agent finds it by wishing: SkillFed indexes 14,416 PyPI packages by what they can do, searchable in plain language.

wish › “distro name and version”

  • distroDistro provides a reliable, machine-readable API to query the Linux…
  • iterative-telemetrySends anonymized telemetry data from Iterative tools, collecting…
  • ramp-packerBundles Redis modules into distributable packages with metadata,…

Give your agent the search over MCP, or paste the wish link into any chat.

More Python Modules packages

idna Worth it
PyPI · Python Modules · released Jun 2026

Converts domain names between Unicode and ASCII-compatible encoding (Punycode) according to IDNA 2008 and Unicode Technical Standard 46, with security validation and broader script coverage than the standard library.

Install it if you work with internationalized domain names, need to validate domains, or use HTTP clients that depend on it transitively.

BSD-3-Clausepure Python · 3.9+
1.8Bdownloads / mo
setuptools Worth it
PyPI · Python Modules · released Aug 2026

Setuptools is a Python build backend and package management tool that handles building, distributing, and installing Python packages, including support for C/C++ extension modules.

MITpure Python · 3.10+
1.6Bdownloads / mo
PyYAML Worth it
PyPI · Python Modules · released Sep 2025

PyYAML parses and emits YAML 1.1 data format, enabling serialization and deserialization of configuration files and Python objects to and from human-readable YAML text.

MITcompiled wheel · 3.8+
1.2Bdownloads / mo
pydantic Worth it
PyPI · Python Modules · released May 2026

Pydantic validates Python data structures against type hints, coercing and checking input at runtime to ensure it matches a declared schema.

MITpure Python · 3.9+
1.1Bdownloads / mo
annotated-types Worth it
PyPI · Python Modules · released Jul 2026

Provides reusable metadata objects for use with PEP-593 `typing.Annotated` to express common constraints like bounds, collection sizes, and predicates on types.

Install it if you use or build libraries that need to express type constraints in a standardized, inspectable way—or if you want to annotate your own types with…

MITpure Python · 3.10+
871.3Mdownloads / mo
typing-inspection Worth it
PyPI · Python Modules · released Aug 2026

Provides runtime tools to inspect and introspect Python type annotations, enabling programmatic examination of type hints at execution time.

MITpure Python · 3.10+
783.0Mdownloads / mo

See also extra-platforms · bindep · distro2sbom · opentelemetry-container-distro · certifi-linux · pkginfo · aws-opentelemetry-distro · abxpkg · distlib · napalm