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

BUG: error importing zmq #1814

Closed
pnael opened this issue Dec 15, 2022 · 4 comments
Closed

BUG: error importing zmq #1814

pnael opened this issue Dec 15, 2022 · 4 comments

Comments

@pnael
Copy link

pnael commented Dec 15, 2022

What pyzmq version?

24.0.1

What libzmq version?

libzmq3-3.2.5_1

Python version (and how it was installed)

python 3.9

OS

Freebsd 13.1-RELEASE-p5

What happened?

I can't import zmq. I am getting this error:
Python 3.9.15 (main, Oct 22 2022, 01:13:09)
[Clang 13.0.0 (git@github.com:llvm/llvm-project.git llvmorg-13.0.0-0-gd7b669b3a on freebsd13
Type "help", "copyright", "credits" or "license" for more information.

import zmq
Traceback (most recent call last):
File "", line 1, in
File "/home/philippe/.local/lib/python3.9/site-packages/zmq/init.py", line 61, in
_load_libzmq()
File "/home/philippe/.local/lib/python3.9/site-packages/zmq/init.py", line 36, in _load_libzmq
from . import libzmq
ImportError: /home/philippe/.local/lib/python3.9/site-packages/zmq/libzmq.cpython-39.so: Undefined symbol "unw_getcontext"

Code to reproduce bug

No response

Traceback, if applicable

No response

More info

No response

@pnael pnael changed the title BUG: pip install --no-binary=:all: pyzmq BUG: error importing zmq Dec 15, 2022
@minrk
Copy link
Member

minrk commented Dec 16, 2022

Please include the full command used to build and install pyzmq, and the pyzmq build output, e.g.

pip install -vv --no-binary pyzmq pyzmq

I'd also recommend using libzmq4 instead of libzmq3, which is ~10 years outdated at this point, I think.

@pnael
Copy link
Author

pnael commented Dec 18, 2022

I hope I got your questions :
[philippe@jupiter ~]$ pip install -vv --no-binary pyzmq pyzmq
Using pip 22.2.2 from /usr/local/lib/python3.9/site-packages/pip (python 3.9)
Defaulting to user installation because normal site-packages is not writeable
Created temporary directory: /tmp/pip-ephem-wheel-cache-5k9t347i
Created temporary directory: /tmp/pip-build-tracker-lekfc55u
Initialized build tracking at /tmp/pip-build-tracker-lekfc55u
Created build tracker: /tmp/pip-build-tracker-lekfc55u
Entered build tracker: /tmp/pip-build-tracker-lekfc55u
Created temporary directory: /tmp/pip-install-hhaiadja
Requirement already satisfied: pyzmq in ./.local/lib/python3.9/site-packages (24.0.1)
Created temporary directory: /tmp/pip-unpack-js6lqfoj
Remote version of pip: 22.3.1
Local version of pip: 22.2.2
Was pip installed by pip? False
Removed build tracker: '/tmp/pip-build-tracker-lekfc55u'

@pnael
Copy link
Author

pnael commented Dec 18, 2022

I will wee if I can try libzmq4

@minrk
Copy link
Member

minrk commented Dec 21, 2022

Make sure to include the output of the build itself. What you've given only shows the output when pyzmq is already installed.

Try making a virtualenv and installing with pip install -v --no-cache pyzmq to avid re-using a past build.

@minrk minrk closed this as completed Feb 22, 2024
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