This repository was archived by the owner on Mar 13, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 5
Is there any benefit in generating _version.py? #123
Copy link
Copy link
Open
Description
In #81 @garryod changed to get __version__ from importlib.metadata:
python3-pip-skeleton/src/python3_pip_skeleton/__init__.py
Lines 1 to 3 in 913fd74
| from importlib.metadata import version | |
| __version__ = version("python3-pip-skeleton") |
This means that we require the module to be installed so we know the version. This means that _version.py is not used, ever. We can clean up here, and stop generating it:
python3-pip-skeleton/pyproject.toml
Lines 50 to 51 in 913fd74
| [tool.setuptools_scm] | |
| write_to = "src/python3_pip_skeleton/_version.py" |
and ignoring it:
python3-pip-skeleton/.gitignore
Line 26 in 913fd74
| **/_version.py |
@garryod @GDYendell @gilesknap @AlexanderWells-diamond: any reason we should not do this?
Metadata
Metadata
Assignees
Labels
No labels