You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
ImportError: failed to find libmagic. Check your installation #278
I ran into this problem on a Apple M1 as at least one other person above did. To fix it, I installed homebrew (https://brew.sh/) and then ran brew install libmagic
After that I was able to successfully import magic for my programs that needed them.
Having this problem inside a Linux container on a Linux machine. Also had it on a Mac. Check out this issue for hundreds of people with this problem using another project that uses this project:
@KaczuH yeah swallowing was a bad call. I don't think there's anything else to do with this issue since it's a local install problem and once in python I'm not sure how to detect it. Closing issue, feel free to re-open if there's anything else to do.
Activity
ahupp commentedon Aug 25, 2022
Could you share more information; platform, how you installed it, the error you're seeing, what you've tried to debug already?
wmazur-splunk commentedon Aug 29, 2022
This PR may help :-) #279
In my case it occurred it's an issue with Apple M1 Silicone (I do not know how to fix it yet)
"mach-o file, but is an incompatible architecture (have (arm64), need (x86_64))"
0xDAV1D-1 commentedon Sep 28, 2022
I ran into this problem on a Apple M1 as at least one other person above did. To fix it, I installed homebrew (https://brew.sh/) and then ran
brew install libmagicAfter that I was able to successfully
import magicfor my programs that needed them.alejandroacho commentedon Feb 4, 2023
But does it has any sense when you are running it into a docker container?
In my case I'm also working with a M1 macbook, but everything is containerized
melyux commentedon Feb 5, 2023
Having this problem inside a Linux container on a Linux machine. Also had it on a Mac. Check out this issue for hundreds of people with this problem using another project that uses this project:
YelpArchive/elastalert#1927
francisbrito commentedon Mar 2, 2023
In case you're Anaconda using as your environment manager:
The command to install
libmagicis:kennethleungty commentedon Mar 3, 2023
How to fix this for Windows and with pip?
KaczuH commentedon May 3, 2023
My coworker has the same issue (running on M1 Mac).
Suprisingly i had no problems despite having M1 Mac myself.
What we think differs between our setups is that my colleague installed python via homebrew and i'm using pyenv,
FInally we've been able to force it to work after following instructions in:
https://medium.com/mkdir-awesome/how-to-install-x86-64-homebrew-packages-on-apple-m1-macbook-54ba295230f
But does feel like workaround not proper solution
@ahupp
PR #279 really could have saved us a lot of debugging.
ahupp commentedon Aug 25, 2023
@KaczuH yeah swallowing was a bad call. I don't think there's anything else to do with this issue since it's a local install problem and once in python I'm not sure how to detect it. Closing issue, feel free to re-open if there's anything else to do.