-
Bug
-
Resolution: Fixed
-
Major
-
3.4.3, 3.5.1
-
MOODLE_34_STABLE, MOODLE_35_STABLE
-
MOODLE_33_STABLE, MOODLE_34_STABLE, MOODLE_35_STABLE
-
wip-
MDL-62574-master -
-
GDPR Followup Sprint 1
As requested by dobedobedoh in the Dev Chat, I am reporting a problem with deleting user data from block_html with the Privacy API.
Steps to reproduce:
- Login as student
- Add a HTML block instance to your dashboard and configure this block instance with some text content
- Open a SSH console
- Pick the "Test of deleting user data" utility from https://docs.moodle.org/dev/Privacy_API/Utilities and store it as deletiontest.php
- Run deletiontest.php with the student which you have used at the beginning of this test
Expected result:
- The script finishes and the student's data is deleted
Actual result:
- The script crashes with a database exception
Entfernen bestätigter 19 Kontexte (Freitag, 25. Mai 2018, 12:18) ausführen
mod_assign wird verarbeitet (1/19) (Freitag, 25. Mai 2018, 12:18)
mod_forum wird verarbeitet (2/19) (Freitag, 25. Mai 2018, 12:18)
mod_lti wird verarbeitet (3/19) (Freitag, 25. Mai 2018, 12:18)
mod_moodleoverflow wird verarbeitet (4/19) (Freitag, 25. Mai 2018, 12:18)
block_html wird verarbeitet (5/19) (Freitag, 25. Mai 2018, 12:18)
Default exception handler: Datensatz kann nicht in der Datenbanktabelle context gefunden werden Debug: SELECT * FROM {context} WHERE id = ?
[array (
0 => '228064',
)]
Error code: invalidrecord
* line 1546 of /lib/dml/moodle_database.php: dml_missing_record_exception thrown
* line 1522 of /lib/dml/moodle_database.php: call to moodle_database->get_record_select()
* line 5060 of /lib/accesslib.php: call to moodle_database->get_record()
* line 117 of /privacy/classes/local/request/contextlist_base.php: call to context::instance_by_id()
* line 288 of /privacy/classes/local/request/helper.php: call to core_privacy\local\request\contextlist_base->current()
* line 108 of /privacy/classes/local/request/helper.php: call to core_privacy\local\request\helper::delete_data_for_user_in_course_module()
* line 378 of /privacy/classes/manager.php: call to core_privacy\local\request\helper::delete_data_for_user()
* line 70 of /deletiontest.php: call to core_privacy\manager->delete_data_for_user()
!!! Datensatz kann nicht in der Datenbanktabelle context gefunden werden !!!
!! SELECT * FROM {context} WHERE id = ?
[array (
0 => '228064',
)]
Error code: invalidrecord !!
!! Stack trace: * line 1546 of /lib/dml/moodle_database.php: dml_missing_record_exception thrown
* line 1522 of /lib/dml/moodle_database.php: call to moodle_database->get_record_select()
* line 5060 of /lib/accesslib.php: call to moodle_database->get_record()
* line 117 of /privacy/classes/local/request/contextlist_base.php: call to context::instance_by_id()
* line 288 of /privacy/classes/local/request/helper.php: call to core_privacy\local\request\contextlist_base->current()
* line 108 of /privacy/classes/local/request/helper.php: call to core_privacy\local\request\helper::delete_data_for_user_in_course_module()
* line 378 of /privacy/classes/manager.php: call to core_privacy\local\request\helper::delete_data_for_user()
* line 70 of /deletiontest.php: call to core_privacy\manager->delete_data_for_user()
!!