Skip to content

ImportError('failed to find libmagic. Check your installation') #126

Description

@caio-pavesi

While trying to run style50 on a ARM with macOS in virtual environment of python 3.13 I've received this error:

style50 degrees.py
Traceback (most recent call last):
  File "/Users/caiopavesi/GitHub/CS50AI/.venv/bin/style50", line 5, in <module>
    from style50.__main__ import main
  File "/Users/caiopavesi/GitHub/CS50AI/.venv/lib/python3.12/site-packages/style50/__init__.py", line 17, in <module>
    from ._api import Style50, StyleCheck, Error
  File "/Users/caiopavesi/GitHub/CS50AI/.venv/lib/python3.12/site-packages/style50/_api.py", line 18, in <module>
    import magic
  File "/Users/caiopavesi/GitHub/CS50AI/.venv/lib/python3.12/site-packages/magic/__init__.py", line 209, in <module>
    libmagic = loader.load_lib()
               ^^^^^^^^^^^^^^^^^
  File "/Users/caiopavesi/GitHub/CS50AI/.venv/lib/python3.12/site-packages/magic/loader.py", line 49, in load_lib
    raise ImportError('failed to find libmagic.  Check your installation')
ImportError: failed to find libmagic.  Check your installation

I've tried to reinstall libmagic and style50, but still it does not work

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions