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

python snappy fails on Mac M2 processor #123

Open
chris1248 opened this issue Nov 7, 2022 · 1 comment
Open

python snappy fails on Mac M2 processor #123

chris1248 opened this issue Nov 7, 2022 · 1 comment

Comments

@chris1248
Copy link

I have installed snappy via brew and that says it installed fine.

But when I pip install python-snappy and then run the following script:

import snappy

compressed = snappy.compress("some data")
assert "some data" == snappy.uncompress(compressed)

it fails with:

(venv) ~/code/projectblue-api/src (feature/ARM/build-stuff) $ python test_snappy.py 
Traceback (most recent call last):
  File "<...snip...>/venv/lib/python3.10/site-packages/snappy/snappy.py", line 48, in <module>
    from ._snappy import UncompressError, compress, decompress, \
ImportError: dlopen(<...snip...>/venv/lib/python3.10/site-packages/snappy/_snappy.cpython-310-darwin.so, 0x0002): symbol not found in flat namespace '_snappy_compress'

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "<...snip...>/src/test_snappy.py", line 1, in <module>
    import snappy
  File "<...snip...>/venv/lib/python3.10/site-packages/snappy/__init__.py", line 3, in <module>
    from .snappy import (
  File "<...snip...>/venv/lib/python3.10/site-packages/snappy/snappy.py", line 51, in <module>
    from .snappy_cffi import UncompressError, compress, decompress, \
  File "<...snip...>/venv/lib/python3.10/site-packages/snappy/snappy_cffi.py", line 3, in <module>
    from ._snappy_cffi import ffi, lib
ModuleNotFoundError: No module named 'snappy._snappy_cffi'
@gliptak
Copy link
Collaborator

gliptak commented Feb 23, 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