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

Update notifications should have a kill switch

    Details

    • Type: Improvement
    • Status: Closed
    • Priority: Blocker
    • Resolution: Fixed
    • Affects Version/s: 2.3
    • Fix Version/s: 2.3
    • Component/s: Administration
    • Labels:
    • Testing Instructions:
      Hide

      Testing difficulty: medium (requires access to the source code)

      1. Put $CFG->disableupdatenotifications = true; into your config.php (there is no corresponding UI setting intentionally)
      2. TEST: Make sure there is no Site administration > Server > Update notifications section available
      3. TEST: Make sure there is no available updates info at the Plugins overview admin page
      4. TEST: Make sure there is no available updates info at the admin Notifications page
      5. Increase the $plugin->version in some of your plugin's version.php file and visit the /admin page
      6. TEST: Make sure there is no available updates info at the Plugins check upgrade page
      7. Execute cron and grap its output
      8. TEST: Make sure there is nothing regarding available updates fetching mentioned in the cron output
      9. Remove the flag from the config.php and ideally make sure that all places mentioned above have the available updates related controls back.

      Show
      Testing difficulty: medium (requires access to the source code) 1. Put $CFG->disableupdatenotifications = true; into your config.php (there is no corresponding UI setting intentionally) 2. TEST: Make sure there is no Site administration > Server > Update notifications section available 3. TEST: Make sure there is no available updates info at the Plugins overview admin page 4. TEST: Make sure there is no available updates info at the admin Notifications page 5. Increase the $plugin->version in some of your plugin's version.php file and visit the /admin page 6. TEST: Make sure there is no available updates info at the Plugins check upgrade page 7. Execute cron and grap its output 8. TEST: Make sure there is nothing regarding available updates fetching mentioned in the cron output 9. Remove the flag from the config.php and ideally make sure that all places mentioned above have the available updates related controls back.
    • Affected Branches:
      MOODLE_23_STABLE
    • Fixed Branches:
      MOODLE_23_STABLE
    • Pull from Repository:
    • Pull Master Branch:
      MDL-32610-hide-updates

      Description

      In a few circumstances (such as completely managed servers, which may have a lot of local modifications) it is desirable to not have the check for updates active.

      Please add a config variable check such as

       if (!empty($CFG->disableupdatenotifications)) {
          return;   // Hide all this functionality from GUI and disable cron checks etc
       }

      so it can be defined in config.php

        Gliffy Diagrams

          Issue Links

            Activity

            Hide
            mudrd8mz David Mudrak added a comment -

            Submitting a patchset for integration. There are couple of places in the code that needed to be wrapped.

            Show
            mudrd8mz David Mudrak added a comment - Submitting a patchset for integration. There are couple of places in the code that needed to be wrapped.
            Hide
            skodak Petr Skoda added a comment -

            It will be funny when the next moodle large scale hack uses this killswitch to disable update notifications...

            Show
            skodak Petr Skoda added a comment - It will be funny when the next moodle large scale hack uses this killswitch to disable update notifications...
            Hide
            mudrd8mz David Mudrak added a comment -

            No worries Petr. We all will blame yourself for publishing the recipe here :-p

            Show
            mudrd8mz David Mudrak added a comment - No worries Petr. We all will blame yourself for publishing the recipe here :-p
            Hide
            samhemelryk Sam Hemelryk added a comment -

            Thanks David, changes look good, has been integrated now.

            Show
            samhemelryk Sam Hemelryk added a comment - Thanks David, changes look good, has been integrated now.
            Hide
            andyjdavis Andrew Davis added a comment -

            Worked as described. Passing.

            Show
            andyjdavis Andrew Davis added a comment - Worked as described. Passing.
            Hide
            stronk7 Eloy Lafuente (stronk7) added a comment -

            U P S T R E A M I Z E D !

            Many thanks for the hard work, closing this as fixed.

            Ciao

            Show
            stronk7 Eloy Lafuente (stronk7) added a comment - U P S T R E A M I Z E D ! Many thanks for the hard work, closing this as fixed. Ciao
            Hide
            tsala Helen Foster added a comment -

            Just noting that this setting is documented here: http://docs.moodle.org/23/en/Notifications

            Show
            tsala Helen Foster added a comment - Just noting that this setting is documented here: http://docs.moodle.org/23/en/Notifications

              People

              • Votes:
                3 Vote for this issue
                Watchers:
                9 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved:
                  Fix Release Date:
                  25/Jun/12