Load setuptools configuration from ``pyproject.toml`` files. **PRIVATE MODULE**: API reserved for setuptools internal usage only.
Function | apply |
Apply the configuration from a ``pyproject.toml`` file into an existing distribution object. |
Function | expand |
Given a configuration with unresolved fields (e.g. dynamic, cmdclass, ...) find their final values. |
Function | load |
Undocumented |
Function | read |
Read given configuration file and returns options from it as a dict. |
Function | validate |
Undocumented |
Class | _ |
Undocumented |
Class | _ |
No class docstring; 0/2 instance variable, 2/3 methods documented |
Exception | _ |
Explicitly inform users that some `pyproject.toml` configuration is *beta* |
Exception | _ |
The given `pyproject.toml` file is invalid and would be ignored. !! |
Function | _ignore |
Undocumented |
Function | _parse |
Undocumented |
Function | _skip |
Be temporarily forgiving with invalid ``pyproject.toml`` |
Type Alias | _ |
Undocumented |
Variable | _logger |
Undocumented |
Distribution
, filepath: _Path
, ignore_option_errors=False) -> Distribution
:
(source)
¶
Apply the configuration from a ``pyproject.toml`` file into an existing distribution object.
dict
, root_dir: Optional[ _Path]
= None, ignore_option_errors: bool
= False, dist: Optional[ Distribution]
= None) -> dict
:
(source)
¶
Given a configuration with unresolved fields (e.g. dynamic, cmdclass, ...) find their final values. :param dict config: Dict containing the configuration for the distribution :param str root_dir: Top-level directory for the distribution/project (the same directory where ``pyproject.toml`` is place) :param bool ignore_option_errors: see :func:`read_configuration` :param Distribution|None: Distribution object to which the configuration refers. If not given a dummy object will be created and discarded after the configuration is read. Used in the case a dynamic configuration (e.g. ``attr`` or ``cmdclass``). :rtype: dict
_Path
, expand=True, ignore_option_errors=False, dist: Optional[ Distribution]
= None):
(source)
¶
Read given configuration file and returns options from it as a dict. :param str|unicode filepath: Path to configuration file in the ``pyproject.toml`` format. :param bool expand: Whether to expand directives and other computed values (i.e. post-process the given configuration) :param bool ignore_option_errors: Whether to silently ignore options, values of which could not be resolved (e.g. due to exceptions in directives such as file:, attr:, etc.). If False exceptions are propagated as expected. :param Distribution|None: Distribution object to which the configuration refers. If not given a dummy object will be created and discarded after the configuration is read. This is used for auto-discovery of packages and in the case a dynamic configuration (e.g. ``attr`` or ``cmdclass``) is expanded. When ``expand=False`` this object is simply ignored. :rtype: dict