Skip to content

distro.id() is returning "amzn" on Amazon Linux AMI release 2018.03 #252

@shughes-uk

Description

@shughes-uk

Documentation states this should return "amazon" as the ID but distro.id() is returning "amzn" instead.

Distro version 1.4

(base) [nnd-user:~]$ pip install distro
Collecting distro
  Using cached https://files.pythonhosted.org/packages/ea/35/82f79b92fa4d937146c660a6482cee4f3dfa1f97ff3d2a6f3ecba33e712e/distro-1.4.0-py2.py3-none-any.whl
Installing collected packages: distro
Successfully installed distro-1.4.0
(base) [nnd-user:~]$ python
Python 3.7.4 (default, Aug 13 2019, 20:35:49)
[GCC 7.3.0] :: Anaconda, Inc. on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import distro
>>> distro.id()
'amzn'
>>> distro.version()
'2018.03'
>>> exit()

/etc/os-release contents

VERSION="2018.03"
ID="amzn"
ID_LIKE="rhel fedora"
VERSION_ID="2018.03"
PRETTY_NAME="Amazon Linux AMI 2018.03"
ANSI_COLOR="0;33"
CPE_NAME="cpe:/o:amazon:linux:2018.03:ga"
HOME_URL="http://aws.amazon.com/amazon-linux-ami/"```

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions