Show the admin a warning if the DB version number is greater than the code version number

Bug #1215271 reported by Aaron Wells
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Mahara
Fix Released
Medium
Robert Lyon

Bug Description

In light of the versioning bug we just had with https://bugs.launchpad.net/mahara/+bug/1207140 , I noticed that Mahara doesn't give you a warning or any kind of notification if the database version number (get_config('version')) is higher than the code version number in htdocs/lib/version.php $config->version.

We should add a check and show a warning to the admin if this is the case.

Revision history for this message
Aaron Wells (u-aaronw) wrote :

The code for this seems to be check_upgrades() in lib/upgrade.php

We should probably also show a similar warning if the version number for any of the plugins is higher in the DB than in the code.

Robert Lyon (robertl-9)
Changed in mahara:
status: In Progress → New
Revision history for this message
Mahara Bot (dev-mahara) wrote : A patch has been submitted for review

Patch for "master" branch: https://reviews.mahara.org/8148

Robert Lyon (robertl-9)
Changed in mahara:
status: New → In Progress
importance: Undecided → Medium
milestone: none → 18.04.0
assignee: Aaron Wells (u-aaronw) → Robert Lyon (robertl-9)
Revision history for this message
Mahara Bot (dev-mahara) wrote : A change has been merged

Reviewed: https://reviews.mahara.org/8148
Committed: https://git.mahara.org/mahara/mahara/commit/64f3d964e7c75fe757e9a616437c4d4910cdb36f
Submitter: Cecilia Vela Gurovic (<email address hidden>)
Branch: master

commit 64f3d964e7c75fe757e9a616437c4d4910cdb36f
Author: Robert Lyon <email address hidden>
Date: Mon Oct 16 14:05:03 2017 +1300

Bug 1215271: Show warning if db is newer than files

And throw error if the site is a production site

behatnotneeded

Change-Id: I5b92ed0b5ab7e91f71afb2b4f3fc22f3805cc928
Signed-off-by: Robert Lyon <email address hidden>

Changed in mahara:
status: In Progress → Fix Committed
tags: added: nominatedfeature
Robert Lyon (robertl-9)
Changed in mahara:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.