Moodle 3.9+ (Build: 20200626)
Me too getting the same error;
I tried to download the H5P.Column activity from the H5p.org and updated in content bank it got updated and again schedule task failed for H5P.course presentation, When I download the h5p course presentation from the H5P.org then I got error mysql server has gone away and unable to delete the file updated in the content bank.
Deleted the local cache, cache and tried no help. Done fresh installation and updating the error here.
Execute scheduled task: Download available H5P content types from h5p.org (core\task\h5p_get_content_types_task)
... started 15:27:01. Current memory use 15.4MB.
... used 10 dbqueries
... used 10.419813156128 seconds
Scheduled task failed: Download available H5P content types from h5p.org (core\task\h5p_get_content_types_task),Can not create file "1/core_h5p/library_sources/0/H5P.Column"
Debug info:
Duplicate entry '88b06733853c58c1ef1f0091cbac4e336fda5734' for key 'mdl_file_pat_uix'
INSERT INTO mdl_files (contextid,component,filearea,itemid,filepath,filename,timecreated,timemodified,mimetype,userid,source,author,license,status,sortorder,contenthash,filesize,pathnamehash) VALUES(?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?)
[array (
0 => 1,
1 => 'core_h5p',
2 => 'library_sources',
3 => 0,
4 => '/',
5 => 'H5P.Column',
6 => 1593683831,
7 => 1593683831,
8 => 'application/zip',
9 => NULL,
10 => 'https://api.h5p.org/v1/content-types/H5P.Column',
11 => NULL,
12 => NULL,
13 => 0,
14 => 0,
15 => 'e609dae9eb4471472cc1340eb9250673aa441f7d',
16 => 4761236,
17 => '88b06733853c58c1ef1f0091cbac4e336fda5734',
)]
Backtrace:
* line 1210 of /lib/filestorage/file_storage.php: call to file_storage->create_file_from_pathname()
* line 239 of /h5p/classes/core.php: call to file_storage->create_file_from_url()
* line 202 of /h5p/classes/core.php: call to core_h5p\core->fetch_content_type()
* line 69 of /lib/classes/task/h5p_get_content_types_task.php: call to core_h5p\core->fetch_latest_content_types()
* line 248 of /lib/cronlib.php: call to core\task\h5p_get_content_types_task->execute()
* line 120 of /lib/cronlib.php: call to cron_run_inner_scheduled_task()
* line 73 of /lib/cronlib.php: call to cron_run_scheduled_tasks()
* line 79 of /admin/cli/cron.php: call to cron_run()