pythonnet / clr-loader

Loader for different .NET runtimes
MIT License
32 stars 23 forks source link

The __version__ attribute is not defined #50

Closed jorgepiloto closed 1 year ago

jorgepiloto commented 1 year ago

🐞 Problem The __version__ attribute is not defined anywhere in the source code. The dynamic field is declared in the pyproject.toml but there is no version specified in the __init__.py top file.

💡 Idea Declare this variable in the __init__.py file. Note the value of the __version__ needs to be updated every time a release is made.

jorgepiloto commented 1 year ago

This is related with #44.

jorgepiloto commented 1 year ago

Pinging @koubaa.

filmor commented 1 year ago

This is not related at all to #44. #44 is about the version that is reported by the framework.

As I noted https://github.com/pythonnet/pythonnet/issues/1909#issuecomment-1250091669, you can just use importlib.metadata.version to retrieve the version, I don't see any point in complicating the build process (which your PR doesn't even touch).