HackSoc / hacksoc.org

HackSoc website
https://www.hacksoc.org
8 stars 17 forks source link

Add extra dependency note for Apple Silicon #186

Closed AaronC81 closed 3 years ago

AaronC81 commented 3 years ago

pygit2 does not ship an ARM binary and tries to use the x86 one, which results in this error on an Apple Silicon chip:

ImportError: dlopen(/Users/aaron/.asdf/installs/python/3.10.0/lib/python3.10/site-packages/pygit2/_pygit2.cpython-310-darwin.so, 0x0002): tried: '/Users/aaron/.asdf/installs/python/3.10.0/lib/python3.10/site-packages/pygit2/_pygit2.cpython-310-darwin.so' (mach-o file, but is an incompatible architecture (have 'x86_64', need 'arm64e')), '/usr/local/lib/_pygit2.cpython-310-darwin.so' (no such file), '/usr/lib/_pygit2.cpython-310-darwin.so' (no such file)

This PR adds an extra note to the the dependency installation part of the README explaining how to fix the issue, by reinstalling pygit2 with --no-binary.

sersorrel commented 3 years ago

that's... a little concerning? do you know if there's a bug open against pygit2 or pip about that? from inspecting the most recent pygit2 universal2 wheel pygit2-1.7.0-cp310-cp310-macosx_10_9_universal2.whl (which i am assuming is what pip installed for you), it does seem like there's an x86_64 binary in there, so at a guess this is a pygit2 problem.

i would somewhat prefer passing explicitly --no-binary pygit2 just so its dependencies are still free to come from wheels, but i don't really care that much

AaronC81 commented 3 years ago

Yep, that's the wheel it's using! I've opened an issue over on pygit2.

LukeMoll commented 3 years ago

For reference, M1/ASi-based Runners may be available sometime in 2020l2

https://github.com/actions/virtual-environments/issues/2187

AaronC81 commented 2 years ago

pygit2 has merged a PR for universal builds, so we should be able to revert this once there's a new release of pygit2 :)