Describe the bug
Even though the invenio-cli check-requirements task passes successfully, when I upload images to a local Invenio RDM instance on macOS they do not result in any canvas entries in the IIIF manifest. This seems to be happening because ImageMagick is failing to load due to not being in any library paths.
Steps to Reproduce
- Create a vanilla Invenio RDM 12 app
- Start the application in service/run mode on macOS (not containerized)
- Create a record with an image upload
- Publish the record
- View the records API endpoint
- Click on the IIIF Manifest link
- See an empty
canvas array
Expected behavior
- Canvas entries are generated
Additional context
This is happening on macOS with ImageMagick installed via Homebrew.
Once I add the following to my shell init script, it's able to find ImageMagick:
export MAGICK_HOME="/opt/homebrew/opt/imagemagick"
export DYLD_LIBRARY_PATH="$MAGICK_HOME/lib:$DYLD_LIBRARY_PATH"
export PATH="$MAGICK_HOME/bin:$PATH"
export PKG_CONFIG_PATH="$MAGICK_HOME/lib/pkgconfig:$PKG_CONFIG_PATH"
I confirmed this by running the following code from the image processor:
import pkg_resources
pkg_resources.get_distribution("wand")
from wand.image import Image
Without the paths set above, I get the following:
OSError: cannot find library; tried paths: []
Describe the bug
Even though the
invenio-cli check-requirementstask passes successfully, when I upload images to a local Invenio RDM instance on macOS they do not result in any canvas entries in the IIIF manifest. This seems to be happening because ImageMagick is failing to load due to not being in any library paths.Steps to Reproduce
canvasarrayExpected behavior
Additional context
This is happening on macOS with ImageMagick installed via Homebrew.
Once I add the following to my shell init script, it's able to find ImageMagick:
I confirmed this by running the following code from the image processor:
Without the paths set above, I get the following:
OSError: cannot find library; tried paths: []