import importlib.metadata


def get_version():
    try:
        return importlib.metadata.metadata('mywatering-client')['Version']
    except (importlib.metadata.PackageNotFoundError, KeyError):
        return "unknown"


__version__ = get_version()
