Library update causes H5P to look for H5P.Components-1.0 instead of H5P.Components-1.0.91

Hello,

I encountered a problem after updating a library in H5P.

Steps to reproduce

1.      Create a new H5P content item.

2.      In the editor, H5P suggests updating the Fill in the Blanks library.

3.      Click Update library.

4.      After that, create a new content item using this library.

Result

The new content produces PHP warnings and does not load correctly.

Example warning:

Warning: opendir(.../wp-content/uploads/h5p/libraries/H5P.Components-1.0): Failed to open directory: No such file or directory
Warning: Unable to open directory .../H5P.Components-1.0

Observation

Existing H5P content created earlier continues to work normally. The problem only occurs with new content created after the library update.

When I checked the server, I noticed that the actual folder is:

H5P.Components-1.0.91

But H5P tries to load:

H5P.Components-1.0

As a temporary workaround I created a copy of the folder named H5P.Components-1.0, and after that the new content started working correctly.

Platform

WordPress 6.9.1

Device

Desktop

Browser

Chrome

H5P plugin version

1.17.1

Content type

Fill in the Blanks

PHP errors

See warning above.

Recent changes

The problem started right after updating the Fill in the Blanks library inside the editor. 

Thank you for your help.

Summary: 
Library update causes H5P to look for H5P.Components-1.0 instead of H5P.Components-1.0.91
Content types: 
otacke's picture

It is actually the other way around: H5P core is looking in the right place, but the folder with the new library should not end in .91.

Known issue, see https://h5p.org/node/1556879

Thank you so much!

We've got the exact same issue with multiple libraries since the friday update on our wordpress site.

It seems to be looking for version x.y when the version is actually x.y.z

otacke's picture

Plenty of people will have that problem. Known issue, see https://h5p.org/node/1556879.

Good afternoon.

Yes, I am having a similar / same issue with two content types that I updated on WordPress- Interactive Video and Drag & Drop. I also noticed that the icons for these two content types no longer display so it may be a similar issue with the library folders. 

For the icons it is trying to open these:

Interactive Video: https://h5p.<domain>.ac.uk/wp-content/uploads/h5p/libraries/H5P.InteractiveVideo-1.28/icon.svg

Drag & Drop: https://h5p.<domain>.ac.uk/wp-content/uploads/h5p/libraries/H5P.DragQuestion-1.15/icon.svg

but neither loads.

For the h5p-components.js file you also get "Failed to load resource: the server responded with a status of 404 ()" for https://h5p.<domain>.ac.uk/wp-content/uploads/h5p/libraries/H5P.Components-1.0/dist/h5p-components.js?ver=1.0.91

For Drag & Drop this file shows this error "Failed to load resource: the server responded with a status of 404 ()": https://h5p.<domain>.ac.uk/wp-content/uploads/h5p/libraries/H5P.DragQuestion-1.15/h5p-drag-question.js?ver=1.15.32

For Interactive Video I get this error "2Failed to load resource: the server responded with a status of 404 ()" for : https://h5p.<domain>.ac.uk/wp-content/uploads/h5p/libraries/H5PEditor.InteractiveVideo-1.26/Scripts/interactive-video-editor.js?ver=1.26.3

H5P Plugin: Version 1.17.1

Thanks

Iain

Attachments: 
otacke's picture

Plenty of people will have that problem. Known issue, see https://h5p.org/node/1556879.