Skip to content

Failures on export loading

A nice export of Himanis was generated ( download link towards a 5.1Gb sqlite file)

But a bunch of issues happen when using load_export on that file:

Images

When creating images, an image server is missing

Images insertion failed: insert or update on table "images_image" violates foreign key constraint "images_image_server_id_97d620d5_fk_images_imageserver_id"
DETAIL:  Key (server_id)=(17) is not present in table "images_imageserver".

It's weird because the image server n°17 is present in the sqlite file

sqlite> select * from image_server;
17|irht|https://iiif.irht.cnrs.fr/iiif||
1|bnf|https://gallica.bnf.fr/iiif||

Elements

Most elements are unable to be created because they lack the images mentionned above

Elements insertion failed: insert or update on table "documents_element" violates foreign key constraint "documents_element_image_id_c756e9ad_fk_images_image_id"
DETAIL:  Key (image_id)=(16cb26f9-eb5f-422f-9ece-d29c787cd11d) is not present in table "images_image".

I guess fixing the initial issue will solve that one too.