Editor not loading in Moodle

I am using H5P on Moodle, and for some reason, my Editor will not load. I just get a messaging that says, "Loading, please wait...".

This happened shortly after I had restored a course from a backup of a course from a different moodle site, but I don't know if that would be the cause or not.

There are no console errors and nothing that I can see from putting the site into debugging mode.

 

BV52's picture

Hi Matt,

In order to give your bug report the best chance of getting answered, please include the following information:

  1. Detailed steps to reproduce the bug (exactly how and when did it happen)
  2. Platform and version number. E.g. Drupal, Wordpress, Moodle.
  3. Mobile or Desktop
  4. Browser: Chrome, Firefox, Safari etc
  5. H5P plugin version
  6. H5P content type and version (if a content type was used), and a sample URL or attached H5P.
  7. Any browser console errors
  8. Any PHP errors
  9. Screenshots if it's a visual problem

The more information you provide, the quicker the community will be able to fix it and the quicker you'll have a working solution!

-BV52

Okay, so here is more information...

Steps to Reproduce

  • Create a course in a DEV instance of Moodle (3.5.1) with H5P (1.10) ( activities (content type interactive videos) on the course.
  • Have a second instance of the Moodle site (PROD) on 3.5.1 with H5P (1.10) pre-installed.
  • Make sure PROD has a course created already, but no H5P plugins
  • Backup the course on DEV
  • Download the back-up
  • On production Restore the downloaded backup Into the previously existing course. 
  • Once the merge is complete, you can try and edit one of the H5P activities that were restored into the course on PROD and the editor does not load.

Platform - Moodle (3.5.1)

Device - All devices (Desktop and Mobile)

Browser - All Browsers

H5P Plugin - Version 1.10

Console Error - Picture attached

Screenshot - Attached

PHP Error -

[16-Jan-2019 16:38:47 Europe/London] Default exception handler: Error writing to database Debug: SQLState: 42000<br>
Error Code: 1088<br>
Message: [Microsoft][ODBC Driver 17 for SQL Server][SQL Server]Cannot find the object "mdl_hvp_libraries_hub_cache" because it does not exist or you do not have permissions.<br>

TRUNCATE TABLE mdl_hvp_libraries_hub_cache
[array (
)]
Error code: dmlwriteexception
* line 489 of \lib\dml\moodle_database.php: dml_write_exception thrown
* line 324 of \lib\dml\sqlsrv_native_moodle_database.php: call to moodle_database->query_end()
* line 431 of \lib\dml\sqlsrv_native_moodle_database.php: call to sqlsrv_native_moodle_database->query_end()
* line 840 of \lib\dml\sqlsrv_native_moodle_database.php: call to sqlsrv_native_moodle_database->do_query()
* line 1921 of \lib\dml\moodle_database.php: call to sqlsrv_native_moodle_database->execute()
* line 1434 of \mod\hvp\classes\framework.php: call to moodle_database->delete_records()
* line 2959 of \mod\hvp\library\h5p.classes.php: call to mod_hvp\framework->replaceContentTypeCache()
* line 2567 of \mod\hvp\library\h5p.classes.php: call to H5PCore->updateContentTypeCache()
* line 2927 of \mod\hvp\library\h5p.classes.php: call to H5PCore->fetchLibrariesMetadata()
* line 383 of \mod\hvp\editor\h5peditor-ajax.class.php: call to H5PCore->updateContentTypeCache()
* line 96 of \mod\hvp\editor\h5peditor-ajax.class.php: call to H5PEditorAjax->isContentTypeCacheUpdated()
* line 254 of \mod\hvp\ajax.php: call to H5PEditorAjax->action()

 

I get the same error when I try and to Update content type cache (Image attached)

Turned out to be an issue with my DB user, it didn't have db_owner and could not make the executions required.

BV52's picture

Hi Matt,

I'm glad it is working for you now if you have further questions feel free to post in the forums.

-BV52

Hi matt_ovitraders,

thanks for your post. My problem is the same. Could you please tell me in some short notes what you have done to fix it? 

Where can I see the db_owner and in which way can I make the executions required?

Thanks a lot! 

 

I am using an MS SQL Server Database so it might not be the same steps for you.

Essentially, what ever user you are using to connect your Moodle site to it's database doesn't have the permissions nessessary to make SQL executions.

So all I did was make sure the user in the database has the proper permissions to make those SQL executions.

Regards,

Matt

Hi Matt,

thanks for your answer. I have changed the data-rights of access (moodle-directory and moodledata-directory) to 777er-main-access - but the problem is there anymore.

Thanks a lot for your support still! I will observe the problem in the next days another time, when I spare time in other projects.

Hi there,

Had the same problem - did even a re-install of H5P plugin and cleaned the cache of the browser and played with the javascript settings of the layout in Moodle site settings. But what me finally helped was just diabling the add blocker of the browser (chrome)....

Hope this will help someone. Cheers. 

My H5P editor is just endlessly loading now - I get a whole list of 503 errors when it happens.

This is a link to log file

https://drive.google.com/file/d/1mSgwhB6dToy_XOdfFBV6P4g1UuF2funE/view?u...

Attachments: 
icc's picture

It looks like there might be some issue with your web server. Have you checked your web server's error_log file?

My H5P editor is just endlessly loading

it started when I set https

 

I've tried it on Chrome, firefox, internet explorer, safari

Attachments: 
BV52's picture

Hi Vladimir,

Would you mind providing the following:

  1. Any browser console errors
  2. Any PHP errors
  3. Web server's error_log file

-BV52

Hi

I reinstalled the plugin and tried the modules one by one Interactive video, course presentation did not work, but after about half an hour it started to work and it looks OK. It also works to edit the function of previously created H5P courses.

BV52's picture

Hi Vladimir,

I'm glad it is working now. If you encounter this again please provide the information above.

-BV52