WillAyd commented on code in PR #644:
URL: https://github.com/apache/arrow-nanoarrow/pull/644#discussion_r1811666939
##########
python/src/nanoarrow/__init__.py:
##########
@@ -75,7 +77,8 @@
from nanoarrow.array import array, Array
from nanoarrow.array_stream import ArrayStream
from nanoarrow.visitor import nulls_as_sentinel, nulls_forbid, nulls_separate
-from nanoarrow._version import __version__ # noqa: F401
+
+__version__ = importlib.metadata.version("nanoarrow")
Review Comment:
As far as whether or not this approach is viable, here is the Python
packaging documentation:
https://packaging.python.org/en/latest/discussions/single-source-version/#single-source-version
The date on that is pretty recent and I believe importlib.metadata was
provisional up until 3.10, so a lot of established packages probably had to
come up with their own solution
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]