mafw.devtools
MAFw development tools package.
This package contains the business logic modules used by the release-mgt
and multiversion-doc CLI scripts. It requires optional development
dependencies (requests, packaging) that are not part of the core
MAFw runtime.
Use ensure_devtools_available() as a guard before importing subpackages.
Functions
Verify that optional development dependencies are importable. |
Exceptions
Base exception for MAFw development tool errors. |
- exception mafw.devtools.DevtoolsError[source]
Bases:
ExceptionBase exception for MAFw development tool errors.
This exception replaces direct usage of
click.ClickExceptionin business-logic modules so that the library layer remains independent of the CLI framework.
- mafw.devtools._read_devtools_deps() list[str][source]
Read the
devtoolsoptional-dependency names from MAFw package metadata.This function requires
packagingto be importable (the caller ensures this). It usesRequirementto parse the dependency specifiers reliably.Falls back to reading
pyproject.tomlfrom the source tree if the installed metadata does not yet include thedevtoolsextra (e.g. stale editable install).- Returns:
List of top-level package names required by the
devtoolsextra.- Return type:
list[str]
- mafw.devtools.ensure_devtools_available() None[source]
Verify that optional development dependencies are importable.
The list of required packages is read from MAFw’s own
[devtools]optional-dependency group inpyproject.toml, keeping it as the single source of truth. The check is performed only once; subsequent calls return immediately.- Raises:
ImportError – If
packagingor any other package from thedevtoolsextra cannot be imported.
- mafw.devtools._devtools_checked: bool = True
Module-level flag to skip repeated import checks after the first successful call.
Modules
CLI sub-package for MAFw development tools. |
|
Dependency management utilities for MAFw development tools. |
|
Documentation management utilities for MAFw development tools. |
|
Git operations for MAFw development tools. |
|
GitLab integration helpers for MAFw development tools. |
|
Release management utilities for MAFw development tools. |