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

Libmagic missing since update to 3.9.15 #161

Closed
timobrembeck opened this issue Oct 25, 2022 · 6 comments
Closed

Libmagic missing since update to 3.9.15 #161

timobrembeck opened this issue Oct 25, 2022 · 6 comments

Comments

@timobrembeck
Copy link

I use python-magic in my project https://github.com/digitalfabrik/integreat-cms and since the update from 3.9.14 to 3.9.15, my builds fail with:

import magic
  File "/home/circleci/project/.venv/lib/python3.9/site-packages/magic/__init__.py", line 209, in <module>
    libmagic = loader.load_lib()
  File "/home/circleci/project/.venv/lib/python3.9/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'm not sure whether it was just a coincidence that libmagic was installed before and now isn't anymore, but just wanted to let you know that the update had this side effect.
For the moment, I just downgraded the image tag. Please let me know whether this was unintentional and will be added again in future versions of this image, or whether I should install this dependency separately in my CircleCI workflow.
Thanks a lot in advance!

timobrembeck added a commit to digitalfabrik/integreat-cms that referenced this issue Oct 25, 2022
@FelicianoTech
Copy link
Contributor

Investigating

@merwan
Copy link

merwan commented Oct 26, 2022

Same issue here with the upgrade from 3.8.14 to 3.8.15, downgrading temporarily until this issue is fixed or we have directions on whether we should manage the dependency by ourselves

@FelicianoTech
Copy link
Contributor

Okay so these were removed and it looks to have happened with the change in the base image from Ubuntu 20.04 to 22.04. We will re-add these libraries and respin these two images so that they are fixed.

I'll update here when they are ready for you to use again.


While I work on this, quick tip I like to give people and one I follow for my own projects. If you identify dependencies for your project, I would install them in your CI config regardless on whether or not our images have them. This way, in a situation like this, your builds won't break. If our images already have it, the package manager will say so and won't do anything (thus saving you time). This tip may not work for every situation but can be helpful.

@FelicianoTech
Copy link
Contributor

These images have been updated and this issue should be resolved.

@merwan
Copy link

merwan commented Oct 27, 2022

Thanks for the tip to add dependencies needed for a project, however it can be quite cumbersome in some cases. Here, libmagic is a dependency of a dependency, and the package is very widely used as stated in the fix for the base image: CircleCI-Public/cimg-base@29db736

That being said, thanks for the update, this solves the issue on our side with the following python:3.8 image:

cimg/python:3.8:
  using image cimg/python@sha256:bc11a82befac6618d9f1b4ac3ec05de2c48d6c3b2a11e50a9928d4b979ac4f1e

@FelicianoTech
Copy link
Contributor

Seems like the fix worked well, closing.

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

3 participants