Igor Sapego created IGNITE-24680: ------------------------------------ Summary: DB API Driver 3: missing _version.txt file when trying to install from pip Key: IGNITE-24680 URL: https://issues.apache.org/jira/browse/IGNITE-24680 Project: Ignite Issue Type: Bug Components: platforms, python, thin client Affects Versions: 3.0 Reporter: Igor Sapego Assignee: Igor Sapego Fix For: 3.1
After pip install pyignite-dbapi I tried to import pyignite_dbapi but it threw an error: {noformat} Python 3.13.2 (tags/v3.13.2:4f8bb39, Feb 4 2025, 15:23:48) [MSC v.1942 64 bit (AMD64)] on win32 Type "help", "copyright", "credits" or "license" for more information. >>> import pyignite_dbapi Traceback (most recent call last): File "<python-input-8>", line 1, in <module> import pyignite_dbapi File "<cut>\AppData\Local\Programs\Python\Python313\Lib\site-packages\pyignite_dbapi\__init__.py", line 17, in <module> __version__ = pkgutil.get_data(__name__, "_version.txt").decode ~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^ File "<cut>\AppData\Local\Programs\Python\Python313\Lib\pkgutil.py", line 453, in get_data return loader.get_data(resource_name) ~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^ File "<frozen importlib._bootstrap_external>", line 1217, in get_data FileNotFoundError: [Errno 2] No such file or directory: '<cut>\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\site-packages\\pyignite_dbapi\\_version.txt' {noformat} *Workaround*: Manually add _version.txt in the mentioned path {noformat} >>> import pyignite_dbapi >>> addr = ['127.0.0.1:10800'] >>> conn = pyignite_dbapi.connect(address=addr, timeout=10) >>> cursor = conn.cursor() >>> cursor.execute('SELECT 1') {noformat} -- This message was sent by Atlassian Jira (v8.20.10#820010)