view configmix/constants.py @ 654:0d6673d06c2c

Add support for using "tomllib" (in Python's stdlib since 3.11) and "tomli" TOML packages. They are preferred if they are found to be installed. But note that the declared dependency for the "toml" extra nevertheless is the "toml" package. Because it is available for all supported Python versions. So use Python 3.11+ or install "tomli" manually if you want to use the alternate packages.
author Franz Glasner <fzglas.hg@dom66.de>
date Thu, 19 May 2022 22:10:59 +0200
parents 4499e9b4855d
children
line wrap: on
line source

# -*- coding: utf-8 -*-
# :-
# :Copyright: (c) 2015-2022, Franz Glasner. All rights reserved.
# :License:   BSD-3-Clause. See LICENSE.txt for details.
# :-
"""Some important public contants

"""

from .compat import u as _u


COMMENTS = [
    _u("__comment"),
    _u("__doc"),
]
"""Prefixes for comment configuration keys that are to be handled as
comments

"""

DIR_PREFIX = _u("<dir>")
"""Prefix for configuration values to read other configuration files from
given directory

"""

DEL_VALUE = _u("{{::DEL::}}")
"""Value for configuration items to signal that the corresponding
key-value is to be deleted when configurations are merged.

Despite having "interpolation" syntax this value will **never** be
substituted.

"""

REF_NAMESPACE = _u("ref")
"""Special internal namespace used for implementation of tree
`references`

"""

NONE_FILTER = _u("None")
"""The public name of the special `None` filter"""

EMPTY_FILTER = _u("Empty")
"""The public name of the special `None` filter"""