Return the package version from the active source of truth.
()
| 28 | |
| 29 | |
| 30 | def get_version() -> str: |
| 31 | """Return the package version from the active source of truth.""" |
| 32 | source_version = _version_from_pyproject() |
| 33 | if source_version is not None: |
| 34 | return source_version |
| 35 | try: |
| 36 | return metadata_version("uncommon-route") |
| 37 | except PackageNotFoundError: |
| 38 | return "0.0.0" |
| 39 | |
| 40 | |
| 41 | VERSION = get_version() |