Uploaded image for project: 'Moodle'
  1. Moodle
  2. MDL-62574

Deleting user data from block_html with the Privacy API crashes (at least with the Privacy API test utility)

XMLWordPrintable

    • MOODLE_34_STABLE, MOODLE_35_STABLE
    • MOODLE_33_STABLE, MOODLE_34_STABLE, MOODLE_35_STABLE
    • wip-MDL-62574-master
    • Hide
      1. Log in as a student
      2. Add an HTML block instance to your dashboard and configure this block instance with some text content
      3. Open a terminal
      4. Download deletiontest.php to your moodle instance's root folder.
      5. Run deletiontest.php with the student which you have used at the beginning of this test

        php deletiontest.php
        

      6. Confirm that the script successfully finishes and that you don't encounter any errors (just like in the description) during script execution.
      7. Confirm that the student's data was deleted (e.g. The student should no longer be able to log into the site)
      Show
      Log in as a student Add an HTML block instance to your dashboard and configure this block instance with some text content Open a terminal Download deletiontest.php to your moodle instance's root folder. Run deletiontest.php with the student which you have used at the beginning of this test php deletiontest.php Confirm that the script successfully finishes and that you don't encounter any errors (just like in the description) during script execution. Confirm that the student's data was deleted (e.g. The student should no longer be able to log into the site)
    • 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

      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()
         !!
        
        

            abgreeve Adrian Greeve
            abias Alexander Bias
            Mihail Geshoski Mihail Geshoski
            Jun Pataleta Jun Pataleta
            Anna Carissa Sadia Anna Carissa Sadia
            Votes:
            1 Vote for this issue
            Watchers:
            5 Start watching this issue

              Created:
              Updated:
              Resolved:

                Estimated:
                Original Estimate - 0 minutes
                0m
                Remaining:
                Remaining Estimate - 0 minutes
                0m
                Logged:
                Time Spent - 30 minutes
                30m

                  Error rendering 'clockify-timesheets-time-tracking-reports:timer-sidebar'. Please contact your Jira administrators.