pylibmc: Error trying to import pylibmc
Hey I seem to be installing fine, I am running Mac OSX 10.7, pylibmc 1.2.3 and I am not sure which version of libmemcached I am running but I just installed it so I assume it is the newest release. The problem occurs when I attempt to import pylibmc. I get the following error:
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "pylibmc/__init__.py", line 70, in <module>
import _pylibmc
ImportError: dlopen(/Library/Python/2.7/site-packages/_pylibmc.so, 2): Symbol not found: _memcached_add
Referenced from: /Library/Python/2.7/site-packages/_pylibmc.so
Expected in: flat namespace
in /Library/Python/2.7/site-packages/_pylibmc.so
About this issue
- Original URL
- State: closed
- Created 12 years ago
- Reactions: 1
- Comments: 26 (13 by maintainers)
Hello, I have similar issue.
I am running macOS with apple silicon. running python 3.7 with
x86
interpreter.after installing
libmemcached
withbrew install libmemcached
I was able to installpylibmc
with the following command:pip install pylibmc==1.6.0 --install-option="--with-libmemcached=/opt/homebrew/Cellar/libmemcached/1.0.18_2"
but while trying to import
pylibmc
it failed with:ImportError: dlopen(.../site-packages/_pylibmc.cpython-37m-darwin.so, 0x0002): symbol not found in flat namespace '_memcached_add'
I am thing that
brew install
compiling the library with apple silicon but then i am trying to use it withx86
interpreter. Any suggestions ?@singhravi1 It does indeed depend on it, but the wheel comes with a “universal library” bundled that runs both on ARM64 and x86. Thanks for your feedback!!!
Ok, I have published pylibmc 1.6.3 with wheels that SHOULD work on ARM64 as well. Anyone able to try?