pytestarch
pytestarch copied to clipboard
Documentation issue: typo in a parameter description
I think you made a typo in the documentation for the parameter regex_exclusions parameter, see :
def get_evaluable_architecture(
root_path: str,
module_path: str,
exclusions: tuple[str, ...] = DEFAULT_EXCLUSIONS,
exclude_external_libraries: bool = True,
level_limit: int | None = None,
regex_exclusions: tuple[str, ...] | None = None,
external_exclusions: tuple[str, ...] | None = None,
regex_external_exclusions: tuple[str, ...] | None = None,
) -> EvaluableArchitecture:
"""Constructs an evaluable object based on the given module.
Args:
root_path: root directory of the source code. Should not be set to a submodule of the top level module.
module_path: path of module to generate the evaluable for. Must be a submodule of the root_path module.
exclusions: pseudo-regex to exclude files and directories from being integrated into the evaluable, e.g. *Test.py. Can only be specified if regex_exclusions is not specified.
external_exclusions: pseudo-regex version of 'external_exclusions' to exclude certain external dependencies from being integrated into the evaluable. Can only be specified if exclude_external_libraries is False and regex_external_exclusions is not specified. Note that child dependencies are not automatically excluded, e.g. if exclusion regex is 'logging', then 'logging.handler' will not be excluded. For exclude this as well, use 'logging.*'.
exclude_external_libraries: if True, external dependencies (defined as all dependencies to module outside the
module_path, including Python built-in modules) will not be taken into account for the dependency analysis. If a parent module (e.g. 'logging') is excluded, so will be child modules (e.g. 'logging.handlers').
level_limit: if not None, specifies the depth of the graph. For example, a limit of 1 will result in only the
modules one level below the module path to be added as nodes. Note that this only applies to the final graph;
all modules will be parsed, the graph will simply be flattened: if a submodule of X imports Y, this import is
then assigned to X instead, if Y is above the level limit.
- regex_exclusions: Proper regex version of 'exclusions'. Can only be specified if regex_exclusions is not specified.
+ regex_exclusions: Proper regex version of 'exclusions'. Can only be specified if exclusions is not specified.
regex_external_exclusions: Proper regex version of 'external_exclusions' to exclude certain external dependencies from being integrated into the evaluable. Can only be specified if exclude_external_libraries is False and external_exclusions is not specified. If a parent module (e.g. 'logging') is excluded, so will be child modules (e.g. 'logging.handlers').
"""