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

If glossary is deleted, glossary block still continues to use it and errors all over the show

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: 1.9
    • Fix Version/s: 1.9, 2.0
    • Component/s: Glossary
    • Labels:
      None
    • Database:
      MySQL
    • Affected Branches:
      MOODLE_19_STABLE
    • Fixed Branches:
      MOODLE_19_STABLE, MOODLE_20_STABLE

      Description

      Investigating.. looks like if the glossary has gone it causes breakage

      Notice: Trying to get property of non-object in /var/www/moodle/blocks/glossary_random/block_glossary_random.php on line 186
      You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'LIMIT 100' at line 5

      SELECT ctx.path, ctx.depth FROM context ctx JOIN course_modules cm ON (cm.course=ctx.instanceid AND ctx.contextlevel=50) WHERE cm.id=

      • line 686 of lib/dmllib.php: call to debugging()
      • line 481 of lib/dmllib.php: call to get_recordset_sql()
      • line 2181 of lib/accesslib.php: call to get_record_sql()
      • line 2521 of lib/accesslib.php: call to create_context()
      • line 186 of blocks/glossary_random/block_glossary_random.php: call to get_context_instance()
      • line 232 of blocks/moodleblock.class.php: call to block_glossary_random->get_content()
      • line 240 of lib/blocklib.php: call to block_base->is_empty()
      • line 281 of course/format/topics/format.php: call to blocks_have_content()
      • line 215 of course/view.php: call to require()

      Error: could not insert new context level "70", instance "".

      • line 2246 of lib/accesslib.php: call to debugging()
      • line 2521 of lib/accesslib.php: call to create_context()
      • line 186 of blocks/glossary_random/block_glossary_random.php: call to get_context_instance()
      • line 232 of blocks/moodleblock.class.php: call to block_glossary_random->get_content()
      • line 240 of lib/blocklib.php: call to block_base->is_empty()
      • line 281 of course/format/topics/format.php: call to blocks_have_content()
      • line 215 of course/view.php: call to require()

      Incorrect context specified

      • line 327 of lib/accesslib.php: call to debugging()
      • line 186 of blocks/glossary_random/block_glossary_random.php: call to has_capability()
      • line 232 of blocks/moodleblock.class.php: call to block_glossary_random->get_content()
      • line 240 of lib/blocklib.php: call to block_base->is_empty()
      • line 281 of course/format/topics/format.php: call to blocks_have_content()
      • line 215 of course/view.php: call to require()

        Attachments

          Activity

            People

            Assignee:
            poltawski Dan Poltawski
            Reporter:
            poltawski Dan Poltawski
            Tester:
            Nobody
            Participants:
            Component watchers:
            Adrian Greeve, Jake Dallimore, Mathew May, Mihail Geshoski, Peter Dias, Sujith Haridasan
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved:
              Fix Release Date:
              3/Mar/08