Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Does not seem to work with Python 3.12 #179

Open
joerivanruth opened this issue Aug 24, 2023 · 1 comment
Open

Does not seem to work with Python 3.12 #179

joerivanruth opened this issue Aug 24, 2023 · 1 comment

Comments

@joerivanruth
Copy link
Contributor

I tried to build and run with Python 3.12 and failed. Basically, there seem to be two problems:

  1. Our run-time dependencies numpy and pandas do not install properly on Python 3.12 yet.
  2. It doesn't seem to bundle the MonetDB shared libraries.

I'm on Debian 12.

I'm not too familiar with MonetDB/e, MonetDBe-Python and Python packaging in general so maybe I did something obvious wrong. Anyway, here's what I did and how it came out:

  1. Create a fresh venv 'buildenv' with python 3.12.0rc1.

  2. In the buildenv, install 'build'

  3. Build using python3 -m build. This yields a file dist/monetdbe-0.11-cp312-cp312-linux_x86_64.whl

  4. Set up a different venv 'runenv'.

  5. If I pip install monetdbe-0.11-cp312-cp312-linux_x86_64.whl, installing the numpy dependency fails because module distutils is missing. Fix this with pip install setuptools.

  6. Now the numpy install fails with module 'pkgutil' has no attribute 'ImpImporter'. Did you mean: 'zipimporter'?.

  7. Work around this by installing prereleases of numpy and pandas that work with 3.12.0rc1: pip install --pre numpy pandas.

  8. Now the pip install *.whl works.

  9. If I now pip install jupyter I can open the basic_example.ipynb notebook. However, running monetdb.connect gives ImportError: libmonetdbe.so.26: cannot open shared object file: No such file or directory. And indeed,

(runenv) » ldd /tmp/jvr/lala/runenv/lib/python3.12/site-packages/monetdbe/_lowlevel.abi3.so
	linux-vdso.so.1 (0x00007ffe48d56000)
	libmonetdbe.so.26 => not found
	libc.so.6 => /lib/x86_64-linux-gnu/libc.so.6 (0x00007f7de5288000)
	/lib64/ld-linux-x86-64.so.2 (0x00007f7de548c000)

If I set LD_LIBRARY_PATH to point to my MonetDB installation, it works. But isn't it supposed to bundle the required libraries in the wheel?

@njnes
Copy link
Member

njnes commented Mar 30, 2024

3.12 is enabled in the github actions

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants