utils

This module contains utility functions for contributors.

package_version(package)

Return version of package as integers (only major, minor, patch).

Parameters

package (str) –

Raises

ValueError – if package doesn’t follow semantic versioning

Returns

package version as a tuple

Return type

Tuple[int, …]

set_module(module)

Decorate class to change its module prefix in the name.

This is intended for the doc, so that objects defined internally can appear in the public API, with all links to decorated objects going there.

Parameters

module (str) – target module

Returns

decorated object

Return type

Callable[[T], T]