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

Unable to uninstall section_links block

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: 2.0.5, 2.1.2, 2.2
    • Fix Version/s: 2.0.6, 2.1.3
    • Component/s: Blocks
    • Labels:
    • Testing Instructions:
      Hide
      • Go to Admin->Plugins->Manage blocks
      • Delete (uninstall) the section_links block
      • TEST: No error happen and you get the message saying that it has been deleted and now needs to be deleted from disk.
      Show
      Go to Admin->Plugins->Manage blocks Delete (uninstall) the section_links block TEST: No error happen and you get the message saying that it has been deleted and now needs to be deleted from disk.
    • Difficulty:
      Easy
    • Affected Branches:
      MOODLE_20_STABLE, MOODLE_21_STABLE, MOODLE_22_STABLE
    • Fixed Branches:
      MOODLE_20_STABLE, MOODLE_21_STABLE
    • Pull from Repository:
    • Pull Master Branch:

      Description

      Apart from any other consideration (I could make a bunch related to that block, grrr), I was testing MDL-30327, and when uninstalling the block I got:

      Debug info: Argument 2 passed to moodle_database::delete_records()
      must be an array, string given, called in blocks/section_links/block_section_links.php
      on line 158 and defined
      Stack trace:
      line 365 of /lib/setuplib.php: coding_exception thrown
      line 1609 of /lib/dml/moodle_database.php: call to default_error_handler()
      line 158 of /blocks/section_links/block_section_links.php: call to moodle_database->delete_records()
      line 255 of /lib/adminlib.php: call to block_section_links->before_delete()
      line 101 of /admin/blocks.php: call to uninstall_plugin()

      Going to fix it now, it's only a matter of M2 API not being used.

        Gliffy Diagrams

          Issue Links

            Activity

            Hide
            stronk7 Eloy Lafuente (stronk7) added a comment -

            Sending to integration

            Show
            stronk7 Eloy Lafuente (stronk7) added a comment - Sending to integration
            Hide
            stronk7 Eloy Lafuente (stronk7) added a comment -

            The fix is trivial, just in 2.2 I've added one TODO about the need to move that to proper component names and use the config API properly.

            Ciao

            Show
            stronk7 Eloy Lafuente (stronk7) added a comment - The fix is trivial, just in 2.2 I've added one TODO about the need to move that to proper component names and use the config API properly. Ciao
            Hide
            samhemelryk Sam Hemelryk added a comment -

            Thanks Eloy this has been integrated now

            Show
            samhemelryk Sam Hemelryk added a comment - Thanks Eloy this has been integrated now
            Hide
            samhemelryk Sam Hemelryk added a comment -

            Passing thanks Eloy

            Show
            samhemelryk Sam Hemelryk added a comment - Passing thanks Eloy
            Hide
            stronk7 Eloy Lafuente (stronk7) added a comment -

            Closing as fixed, many thanks for your effort!

            Note that the changes related to master (2.2beta) have been already sent upstream. But the stable ones will be part of next weeklies (Wed/Thu) as usual.

            Ciao

            Show
            stronk7 Eloy Lafuente (stronk7) added a comment - Closing as fixed, many thanks for your effort! Note that the changes related to master (2.2beta) have been already sent upstream. But the stable ones will be part of next weeklies (Wed/Thu) as usual. Ciao

              People

              • Votes:
                0 Vote for this issue
                Watchers:
                0 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved:
                  Fix Release Date:
                  28/Nov/11