如何理解 python 配置文件中的 `::`?

How to understand the `::` in the python config file?

来自 github 地址:

https://github.com/openstack/nova/blob/master/setup.cfg

setup.cfg中,有如下代码:

[metadata]
name = nova
summary = Cloud computing fabric controller
description-file =
    README.rst
author = OpenStack
author-email = openstack-dev@lists.openstack.org
home-page = http://docs.openstack.org/developer/nova/
classifier =
    Environment :: OpenStack
    Intended Audience :: Information Technology
    Intended Audience :: System Administrators
    License :: OSI Approved :: Apache Software License
    Operating System :: POSIX :: Linux
    Programming Language :: Python
    Programming Language :: Python :: 2
    Programming Language :: Python :: 2.7

[]中的内容表示配置名称。比如name表示key,下面表示value.

但是Environment :: OpenStack呢,::有实际意义吗?

不,:: 除了为 Trover classifier levels 选择的定界符外没有特殊含义。

分类器只是元数据,可帮助人们找到特定的包并了解包的内容。包维护者在编写 setup.py 脚本时选择这些; setup.cfg 文件是另一种指定方式。

在这种情况下,双冒号是分类器名称空间分隔符。这不是 Python 语法,它是 PyPI.

上类别的命名约定